Search Results

Search: Posts Made By: Mr_Keystrokes
1,772
Posted By Mr_Keystrokes
I change directory into cd...
I change directory into cd /home/p995824/programs/kmerid-master/ because the setup.py script is in there where I run it.
Good point, I only need new_fldr=${fldr##*/} because the folder names are...
1,772
Posted By Mr_Keystrokes
Trying to loop through folders and execute an existing python script.
I am trying to loop through lots and lots of folders and use the names of the folders to run a Python script which has parameters.
E.g.
-- setup_refs -n John -f England/London/Hackney/John -c...
1,770
Posted By Mr_Keystrokes
Good shout, it's not needed since I'm not copying...
Good shout, it's not needed since I'm not copying folders. I think it's a bad habit of mine since I tend to copy folders around a lot.
1,770
Posted By Mr_Keystrokes
Solved...
I realised that I was copying all the files into all the folders based on the type of file i.e. .fna.gz, so I specified what type of fna.gz file I want to be read and then copied. There is no need...
1,770
Posted By Mr_Keystrokes
This is what I have now, but still no success. ...
This is what I have now, but still no success.



cd /home/scripts/playground/genomes_2 ;

for fldr in /home/scripts/playground/genomes_2/* ; do

find . -name *fna.gz | while read f ;...
1,770
Posted By Mr_Keystrokes
f_name is supposed to be the name, so it's used...
f_name is supposed to be the name, so it's used as a reference point because these files are something like "Long_John_Silver" but the folders into which they're supposed to be placed are like...
1,770
Posted By Mr_Keystrokes
Copying specific file types to specific folders
I am trying to write a script that cycles through a folder containing many folders and when inside each one it's supposed to copy all the .fna.gz files to a folder elsewhere if the file and the...
2,004
Posted By Mr_Keystrokes
Updated script
My script works now.
I now need to add another step to the process and I'll no doubt be back if I run into a stumblingblock again.
855
Posted By Mr_Keystrokes
Testing for the presence or absence of a folder
My directory: /folder1/folder2/file.fna.gz

Now following on from renaming the files of interest (fna.gz) I now need to loop through folder1.
As I loop through folder1 I am trying to first of all...
2,004
Posted By Mr_Keystrokes
My directory: /folder1/folder2/file.fna.gz ...
My directory: /folder1/folder2/file.fna.gz

Now following on from renaming the files of interest (fna.gz) I now need to loop through folder1.
As I loop through folder1 I am trying to first of all...
2,004
Posted By Mr_Keystrokes
It lists all the directories from the root, even...
It lists all the directories from the root, even though I've changed directories to where I want the work to be done. It's okay @rdtx1's solution worked. I just need to build on that now.
...
2,004
Posted By Mr_Keystrokes
Thanks, your solution works. I'm just trying to...
Thanks, your solution works. I'm just trying to decode what you've done.

So I see here that the find function looks for files of a given type i.e. .fna.gz.
And then the pipe ( | ) passes each...
2,004
Posted By Mr_Keystrokes
It returns unwanted files and folders.
It returns unwanted files and folders.
2,004
Posted By Mr_Keystrokes
Looping through all folders in a folder.
I am trying to write a script that loops through all the folders within a given folder.
My intention is to access each folder and rename each file ending with fna.gz with the name of the folder it...
Showing results 1 to 14 of 14

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