Jump to content

Wikipedia:Reference desk/Archives/Computing/2024 June 12

From Wikipedia, the free encyclopedia
Computing desk
< June 11 << May | June | Jul >> June 13 >
Welcome to the Wikipedia Computing Reference Desk Archives
The page you are currently viewing is a transcluded archive page. While you can leave answers for any questions shown below, please ask new questions on one of the current reference desk pages.


June 12

[edit]

Any recent usage statistics on the .zip top-level domain?

[edit]

 Courtesy link: Draft:.zip

Hi, are there any sources or recent publications that show how the TLD is being used, or by whom its being registered (i.e.: percentage of personal vs registered corporations, or location of registration according to WHOIS information)? There was of course a lot of ink spilled regarding the potential for misuse when the registry was created, but I'm looking to see if anyone came back and did a study or research after the fact.

Thanks, microbiologyMarcus [petri dish·growths] 15:47, 12 June 2024 (UTC)[reply]

Easy way of generating "mylist.txt" files from a folder?

[edit]

I have a bunch of folders consisting of mp3 files, which I would like to concatenate via ffmpeg. I am using the method described here, in which the full paths of all the files one wishes to concatenate are named in a text folder using the format of file '[file path]'. It's very tedious having to copy and paste the paths of every single file in a folder, so I'm wondering if there's any program that can scan a folder and output this kind of text file. Cheers, Mach61 17:07, 12 June 2024 (UTC)[reply]

On what system? On Windows, taking a lazy approach (rather than writing a script), you could open a command prompt in the folder (right-click somewhere that isn't on a file and choose "open in terminal"), and then dir/B gives you all the file names. Since they're all in the same folder, copy and paste the list to a text editor and paste file ' and the path of the folder in front of each line, then put ' after each line. Repeat with next folder. Still effort, but less effort, and gets the job done.  Card Zero  (talk) 19:39, 12 June 2024 (UTC)[reply]
When I required a list of all files within a folder structure, I found that doing it with DOS ("Command Prompt" these days) was the simplest, though there was a bit of work to deal with the resultant file. In DOS, I went to the base folder I wanted to harvest and used DIR to fetch the filenames and paths. Something like DIR /S >OUTPUT.TXT (The /s command tells it to bring back the sub-directories and the > tells it to input to a (text) file. I then imported the result into Excel and was able to get what I wanted. Matt Deres (talk) 19:40, 12 June 2024 (UTC)[reply]
Just to build on that a bit: the trickiest part was getting the pathways to correctly get matched up with the filenames. Most of the problem came from the way Excel would split the text into columns: the rules for what you want it to do for the files is not the same as what you want it to do with the folder information. There's probably a clever way around that, but I ended up using some really kludge-y formulas and then correcting. It's not something I'd want to have to do every day, but as a one-time thing it was okay. Matt Deres (talk) 19:46, 12 June 2024 (UTC)[reply]
Try https://www.karenware.com/powertools/karens-directory-printer and then running a macro or using search&replace in Notepad++ Polygnotus (talk) 02:32, 13 June 2024 (UTC)[reply]
On Linux I do ls -1 | awk '{ print("file \x27"ENVIRON["PWD"]"/"$0"\x27")}' > /tmp/mylist.txt You might be able to do the same on Windows using Cygwin. You will need to rename if the filename has a single quote in it, eg Return to Castle De'ath Track 01.mp3 which I had to deal with recently. TrogWoolley (talk) 08:35, 13 June 2024 (UTC)[reply]
A slightly simpler way to do it on Linux would be
for f in *; do echo "file '$PWD/$f'"; done >/tmp/mylist.txt CodeTalker (talk) 05:25, 14 June 2024 (UTC)[reply]

~