Search Results

Search: Posts Made By: shadok
22,502
Posted By shadok
Continue an instruction on more than one line in a script shell ?
Hello,

I have a very long instruction to write, but, for lisibility reasons, I would like to cut it on more than one line and comment each lines.

is it possible ?

thanks :b:
1,474
Posted By shadok
Ok, I can't use these syntax since I need...
Ok,

I can't use these syntax since I need only some lines of my file and on each line some arguments.

So, I just want to know how to split with the blanks, the line that was read and stored in...
1,474
Posted By shadok
your solution don't seem to work: ...
your solution don't seem to work:

shadok@pomputer:~$ a=head -3 candyfile.doc | tail -1
shadok@pomputer:~$ echo $a
T 50 2 3.5 is this a candy color price
pomputer:~$ while read $a; do echo...
1,474
Posted By shadok
Split string with blancs to pick up information in a file ?
Hello,

I am quite new in shell, and would like to pick up information in a file.

The file structure is like this faor all data:


T 50 2 2.5 is this a candy number color price

I...
1,235
Posted By shadok
ahamed, ok, thanks it works :)
ahamed,

ok, thanks it works :)
1,235
Posted By shadok
Simple string manipulation
Hello,

I would like to make simple string manipulation but since i am new in shell scripting some strange stuff are uncomprehensible to me:

I would like to pick up the name of a file and put it...
1,984
Posted By shadok
THANKS ! it works perfectly now ! :D :b: ...
THANKS ! it works perfectly now !

:D :b:

But why thes space are so important ? :confused:
1,984
Posted By shadok
Hello, I tried your solution but apprently,...
Hello,

I tried your solution but apprently, the test doesn't work well since no action that have to be done if the "if" test are done.

I tried to replace the test from
if [ -f $target_file]
...
1,984
Posted By shadok
Sorry, I was not very clear :wall: What I...
Sorry, I was not very clear :wall:

What I want is that:

step 1:
in path1/rep1/

cp file1.f90 file1_old.f90

but for all f90 files and i don't know how to easily manipulate filename string...
1,984
Posted By shadok
Script to List, Modify, replace filename for an upload?
Hello, here is my problem:

I have ma program in a first directory dir1:

ls path1/rep1/
file1.f90 file1.f90~ file1.o file2.f90 .... etc...


I have modified folder in an other directory:
...
7,599
Posted By shadok
thanks! It's much more simple like that ! I...
thanks! It's much more simple like that !

I feel stupid ! lol :wall:
7,599
Posted By shadok
How to read a file line by line and store it in a variable to execute a program ?
Hello, I am quite new in shell scripting and I would like to write a little scritp to run a program on some parameters files.

all my parameters files are in the same directory, so pick them up...
Showing results 1 to 12 of 12

 
All times are GMT -4. The time now is 05:23 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy