Search Results

Search: Posts Made By: zioalex
83,906
Posted By Scrutinizer
while read line; do echo ${line%????} done...
while read line; do
echo ${line%????}
done < infile

---------- Post updated at 22:39 ---------- Previous update was at 22:31 ----------

awk '{sub(/....$/,"")}1' infile

---------- Post...
83,906
Posted By danmero
or AWK awk '{print substr($0,(length($0)-3))}'...
or AWK
awk '{print substr($0,(length($0)-3))}' FILE
83,906
Posted By ghostdog74
bash while read -r line do echo...
bash

while read -r line
do
echo ${line:(-4)}
done < "file"
83,906
Posted By Scott
You want to remove the last four characters or...
You want to remove the last four characters or keep them?

You say remove them, then say:


Remove
sed "s/....$//" file1
iwishicouldremove
icouldremove


Keep

sed "s/.*\(....$\)/\1/"...
Forum: Tips and Tutorials 07-31-2005
756,442
Posted By Perderabo
mtime, ctime, and atime
Unix keeps 3 timestamps for each file: mtime, ctime, and atime. Most people seem to understand atime (access time), it is when the file was last read. There does seem to be some confusion between...
Showing results 1 to 5 of 5

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