0
votes
2answers
389 views

Using a file input as stdin for a shell script does not work

I have the following script code: test.sh echo "BEGIN" while read CMD <&1; do [ -z "$CMD" ] && continue case "$CMD" in start) echo "get_start" ;; ...
1
vote
2answers
616 views

Unix moving/removing files from subdirectories

if there are several subdirectories in the current working directory, i would like to move only specific filetypes or possibly all the contents of those directories, to the working directory. and ...
3
votes
3answers
55 views

Show Which Remote File is Writing My File

I know it sounds funny. I wrote a shell script and executed on a remote machine to ssh back to my local machine to write some files. I executed the script on various remote machines and I can't ...
2
votes
1answer
158 views

Copy all files in a folder which have the same name as files in a separate folder

Let me explain: I am going through a huge icon set, and choosing the icons I like. I have chosen maybe 250 out of 3000 icons. The way the icons are split up are like this: Icons -> 16x16 ...
0
votes
1answer
541 views

how to convert line-delimited txt file into a spreadsheet file as tsv or xls

I have a huge amount of phone numbers (for example), one for each line in .txt file. 202898990 909090090 909090900 ... I want to put each number in a a cell (phone numbers in the same column). I ...
0
votes
2answers
293 views

Search for exe file within a condition

I want to search for all .exe files greater than 200 kB or smaller than 120 kB in the current folder and its subfolders. Then I want to move them to another folder called "folder" and execute in this ...
0
votes
2answers
3k views

Cutting and moving files using the Linux terminal

What is the command I can use to cut and then move a file from one location to another from a Linux terminal? Is there any website that lists all the commands for a Linux terminal?
0
votes
5answers
304 views

What is the shortest most readable way to print the n'th line of a file?

Its about Unix and Linux. Yes, there are many solutions to that, e.g. see http://mywiki.wooledge.org/BashFAQ/011. Some of them are fast as hell (not reading the whole file) and some are slow but ...
1
vote
1answer
416 views

mv - move dir with destination-dir having the same subdirs as source-dir

In FreeBSD (I suppose it works like Linux et al in this regard), I'd like to move src_parent/mydir to dst_parent/mydir. dst_parent/mydir already exists, and it contains some subdirs that's also ...
0
votes
1answer
392 views

Using the Linux split command to create N Files

I need to split files into guaranteed number of buckets. The size do not have to be equal. Here is my logic count = wc -l filename split_count = (count)/4 split -l split_count filename core_ ...
3
votes
1answer
574 views

Windows 7 Primary Folder Icon File?

In Windows XP and earlier, when changing a folder's icon, you can select system32\shell32.dll for a wide selection of built-in windows icons that include most folder types. In Windows 7, you can ...
2
votes
4answers
655 views

Linux shellscript combine all files without for loop

I have hundreds of files in one directory, is there a simple command or pipes of command I can use to append them together? I don't want to use any loops.
1
vote
3answers
489 views

Easiest way to automatically copy files between computers

I am trying to write a script which will essentially copy and file in a certain folder to a folder on another computer. My first thought was SCP, but I don't know if I can automate SCP by adding a ...
1
vote
4answers
746 views

What do .# file names mean in Linux?

This is probably trivial, but I'm quite new to Linux and I was unable to find any info online. In a folder, I can execute the command find . -regex '.*py' and get the following result: ...