how can i create a file and add to it periodically, retaining the contents of the fileThe profile of gnome-terminal isnt correctly loaded by command line startHow can I get a file's UbuntuOne URL from the terminal?How does gedit detect the encoding of a text file?does << (input redirection in append mode ) works only for newline?Need audio player for bash scriptWant to write a bash script to automate creating program filesCrontab script not running (16.04)How do I get the contents of a 1-line text file into the bash command buffer?How can I avoid having to enter a password for an scp command by hard-coding the password into my script?Creating a .bash file to test for loop
Alternative to sending password over mail?
High voltage LED indicator 40-1000 VDC without additional power supply
If human space travel is limited by the G force vulnerability, is there a way to counter G forces?
What typically incentivizes a professor to change jobs to a lower ranking university?
Languages that we cannot (dis)prove to be Context-Free
Perform and show arithmetic with LuaLaTeX
Why is consensus so controversial in Britain?
Is it legal for company to use my work email to pretend I still work there?
Arrow those variables!
Modeling an IP Address
How do I draw and define two right triangles next to each other?
Why is 150k or 200k jobs considered good when there's 300k+ births a month?
Client team has low performances and low technical skills: we always fix their work and now they stop collaborate with us. How to solve?
What is the word for reserving something for yourself before others do?
Intersection point of 2 lines defined by 2 points each
NMaximize is not converging to a solution
"You are your self first supporter", a more proper way to say it
tikz convert color string to hex value
Is it tax fraud for an individual to declare non-taxable revenue as taxable income? (US tax laws)
Are the number of citations and number of published articles the most important criteria for a tenure promotion?
Can I ask the recruiters in my resume to put the reason why I am rejected?
Can you really stack all of this on an Opportunity Attack?
Do I have a twin with permutated remainders?
How does quantile regression compare to logistic regression with the variable split at the quantile?
how can i create a file and add to it periodically, retaining the contents of the file
The profile of gnome-terminal isnt correctly loaded by command line startHow can I get a file's UbuntuOne URL from the terminal?How does gedit detect the encoding of a text file?does << (input redirection in append mode ) works only for newline?Need audio player for bash scriptWant to write a bash script to automate creating program filesCrontab script not running (16.04)How do I get the contents of a 1-line text file into the bash command buffer?How can I avoid having to enter a password for an scp command by hard-coding the password into my script?Creating a .bash file to test for loop
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;
I've looked around AskUbuntu, as well as just trying on the internet; but i can see no solution, every time i change my coding.
I run Ubuntu 18.04.1 (in case that matters)
and i want to have a simple script that will allow data to be added to a file, but if the file already exists, to allow it to continue from where it left off at the beginning.
so i want file to be created and the first piece of information put into it from a 3rd party source.
then i want now that the file already exists, i want it to add new information at the bottom of the existing text
for egg sample
- the file does not exist
- a file is created (called "mylog")
- information is added to the first line of the file and a newline is
created to move the cursor to the beginning of the next available
line. - The file contains all the log information i needed by monitoring them
for me - while i learn sleep patterns again.
Is this even possible on Ubuntu, Am I missing the obvious; the irony is that i can do it in DOS with my eyes closed.
Thanks in advance; please refer to similar questions if you think they will help, i personally was just not able too.
I've been trying to do it with gedit and a terminal to run it each time to test. If you can do it with bash, that would be great, if you think something better, that's perfectly acceptable, i Just use Bash because it's my favourite, but I'm not married to it.
command-line bash scripts gnome-terminal gedit
add a comment |
I've looked around AskUbuntu, as well as just trying on the internet; but i can see no solution, every time i change my coding.
I run Ubuntu 18.04.1 (in case that matters)
and i want to have a simple script that will allow data to be added to a file, but if the file already exists, to allow it to continue from where it left off at the beginning.
so i want file to be created and the first piece of information put into it from a 3rd party source.
then i want now that the file already exists, i want it to add new information at the bottom of the existing text
for egg sample
- the file does not exist
- a file is created (called "mylog")
- information is added to the first line of the file and a newline is
created to move the cursor to the beginning of the next available
line. - The file contains all the log information i needed by monitoring them
for me - while i learn sleep patterns again.
Is this even possible on Ubuntu, Am I missing the obvious; the irony is that i can do it in DOS with my eyes closed.
Thanks in advance; please refer to similar questions if you think they will help, i personally was just not able too.
I've been trying to do it with gedit and a terminal to run it each time to test. If you can do it with bash, that would be great, if you think something better, that's perfectly acceptable, i Just use Bash because it's my favourite, but I'm not married to it.
command-line bash scripts gnome-terminal gedit
add a comment |
I've looked around AskUbuntu, as well as just trying on the internet; but i can see no solution, every time i change my coding.
I run Ubuntu 18.04.1 (in case that matters)
and i want to have a simple script that will allow data to be added to a file, but if the file already exists, to allow it to continue from where it left off at the beginning.
so i want file to be created and the first piece of information put into it from a 3rd party source.
then i want now that the file already exists, i want it to add new information at the bottom of the existing text
for egg sample
- the file does not exist
- a file is created (called "mylog")
- information is added to the first line of the file and a newline is
created to move the cursor to the beginning of the next available
line. - The file contains all the log information i needed by monitoring them
for me - while i learn sleep patterns again.
Is this even possible on Ubuntu, Am I missing the obvious; the irony is that i can do it in DOS with my eyes closed.
Thanks in advance; please refer to similar questions if you think they will help, i personally was just not able too.
I've been trying to do it with gedit and a terminal to run it each time to test. If you can do it with bash, that would be great, if you think something better, that's perfectly acceptable, i Just use Bash because it's my favourite, but I'm not married to it.
command-line bash scripts gnome-terminal gedit
I've looked around AskUbuntu, as well as just trying on the internet; but i can see no solution, every time i change my coding.
I run Ubuntu 18.04.1 (in case that matters)
and i want to have a simple script that will allow data to be added to a file, but if the file already exists, to allow it to continue from where it left off at the beginning.
so i want file to be created and the first piece of information put into it from a 3rd party source.
then i want now that the file already exists, i want it to add new information at the bottom of the existing text
for egg sample
- the file does not exist
- a file is created (called "mylog")
- information is added to the first line of the file and a newline is
created to move the cursor to the beginning of the next available
line. - The file contains all the log information i needed by monitoring them
for me - while i learn sleep patterns again.
Is this even possible on Ubuntu, Am I missing the obvious; the irony is that i can do it in DOS with my eyes closed.
Thanks in advance; please refer to similar questions if you think they will help, i personally was just not able too.
I've been trying to do it with gedit and a terminal to run it each time to test. If you can do it with bash, that would be great, if you think something better, that's perfectly acceptable, i Just use Bash because it's my favourite, but I'm not married to it.
command-line bash scripts gnome-terminal gedit
command-line bash scripts gnome-terminal gedit
asked 4 mins ago
SPooKYiNeSSSPooKYiNeSS
3051316
3051316
add a comment |
add a comment |
0
active
oldest
votes
Your Answer
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "89"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1131609%2fhow-can-i-create-a-file-and-add-to-it-periodically-retaining-the-contents-of-th%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
0
active
oldest
votes
0
active
oldest
votes
active
oldest
votes
active
oldest
votes
Thanks for contributing an answer to Ask Ubuntu!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1131609%2fhow-can-i-create-a-file-and-add-to-it-periodically-retaining-the-contents-of-th%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown