Search Results

Search: Posts Made By: 1988PF
1,622
Posted By 1988PF
Write a shell program with input
Hi,

Here is my question:

I want a shell script which I name as 'del', and can be used as del(string).

when run del(string), it will delete several directories at different locations in my...
28,587
Posted By 1988PF
could you also explain a little bit about this...
could you also explain a little bit about this line? Thanks!
28,587
Posted By 1988PF
Thanks. Could you explain a little bit about this...
Thanks. Could you explain a little bit about this line
tmp=$(echo "$fname" | awk -F '_' '{print $4}' )
28,587
Posted By 1988PF
extract string from file name between two underscores
Hi,

Here is my question,

I need to extract string between two underscores from the filename

for example, filename is

atmos_8xdaily_instant_300x300_1_12.nc

what I want to extract is...
1,497
Posted By 1988PF
extract every filename containing certain string in a directory and do some commend per file
Hi,

Here is my question: suppose I have files like
1990_8xdaily_atmos.nc
1991_8xdaily_atmos.nc
1992_8xdaily_atmos.nc
1993_8xdaily_atmos.nc
1990_daily_atmos.nc
1991_daily_atmos.nc...
56,054
Posted By 1988PF
cannot pass a echo output to a variable in bash
Hi,

I have a problem with passing a echo output into a variable in bash

file='1990.tar'
NAME='echo $file | cut -d '.' -f1';
echo $NAME


the result is
echo $file | cut -d . -f1

...
Showing results 1 to 6 of 6

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