Difference between revisions of "Computer Productivity Hacks"

From TeleCafeWiki
Jump to navigation Jump to search
(→‎Rename Multiple Folders / Directories With Batch File: .bat file for renaming multiple folders)
 
(45 intermediate revisions by the same user not shown)
Line 1: Line 1:
 
{{RightTOC}}
 
{{RightTOC}}
 
== Command Line ==
 
== Command Line ==
* [http://www.enterprisenetworkingplanet.com/windows/article.php/3911386/Manage-Network-Tasks-From-the-Windows-Command-Prompt.htm Manage Network Tasks From the Windows Command Prompt]
+
* [http://www.computerhope.com/jargon/c/commandl.htm Command language]
: Mounting shared drives and connecting to remote resources is something you can easily do from the Windows GUI. With our quick guide to the command prompt, however, you can more easily automate large tasks.
+
: Sometimes referred to as a command script, a [[wikipedia:Command language|command language]] is a language used for executing a series of commands that would otherwise be executed at the prompt. A good example of a command language is Microsoft Windows batch files. Although command languages are useful for executing a series of commands, their functionality is limited to what is available at the command line which can make them easier to learn.
  
 
* [http://learncodethehardway.org/cli/book/cli-crash-course.html Command Line Crash Course]
 
* [http://learncodethehardway.org/cli/book/cli-crash-course.html Command Line Crash Course]
 
: Quick super fast course in using the command line. It is intended to be done rapidly in about a day or two, and not meant to teach you advanced shell usage.
 
: Quick super fast course in using the command line. It is intended to be done rapidly in about a day or two, and not meant to teach you advanced shell usage.
 +
 +
=== Bash & Linux Commands ===
 +
* [http://searchenterpriselinux.techtarget.com/tutorial/77-useful-Linux-commands-and-utilities 77 useful Linux commands and utilities]
 +
 +
* [http://ss64.com/bash/ An A-Z Index of the Bash command line for Linux.]
 +
 +
* [http://askubuntu.com/questions/86822/how-can-i-copy-the-contents-of-a-folder-to-another-folder-in-a-different-directo How can I copy the contents of a folder to another folder in a different directory using terminal?]
 +
 +
* [http://superuser.com/questions/335376/how-to-list-folders-using-bash-commands/335380 How to list folders using bash commands?]
 +
 +
* [http://stackoverflow.com/questions/4263156/how-to-untar-all-tar-gz-with-shell-script How to untar all .tar.gz with shell-script?]
 +
: Got a bunch of <tt>.tar.gz</tt> files you want to unpack onto a server at the same time. Then this tutorial is for you.
  
 
=== WGET ===
 
=== WGET ===
Line 39: Line 51:
 
* [http://pcsupport.about.com/od/commandlinereference/p/xcopy-command.htm Xcopy]
 
* [http://pcsupport.about.com/od/commandlinereference/p/xcopy-command.htm Xcopy]
 
: The xcopy command is a Command Prompt command used to copy one or more files and/or folders from one location to another location.
 
: The xcopy command is a Command Prompt command used to copy one or more files and/or folders from one location to another location.
 +
 +
* [http://stackoverflow.com/questions/60034/how-can-you-find-and-replace-text-in-a-file-using-the-windows-command-line-envir How can you find and replace text in a file using the Windows command-line environment?]
 +
: This question is answered in numerous ways. Many of the answers point to useful utilities to accomplish find-and-replace.
 +
 +
==== [[wikipedia:cmd.exe|Command Prompt]] ====
 +
* [http://superuser.com/questions/205359/how-can-i-open-a-command-prompt-in-current-folder-with-a-keyboard-shortcut How can I open a command prompt in current folder with a keyboard shortcut?]
 +
* [http://superuser.com/questions/946860/how-to-open-windows-cmd-so-that-it-starts-in-the-current-folder How to open Windows CMD so that it starts in the current folder?]
 +
# Open desired directory in windows explorer.
 +
# Hold down shift and right click.
 +
# Select open command window here from menu.
 +
 +
* [http://www.enterprisenetworkingplanet.com/windows/article.php/3911386/Manage-Network-Tasks-From-the-Windows-Command-Prompt.htm Manage Network Tasks From the Windows Command Prompt]
 +
: Mounting shared drives and connecting to remote resources is something you can easily do from the Windows GUI. With our quick guide to the command prompt, however, you can more easily automate large tasks.
 +
 +
* [http://superuser.com/questions/303484/windows-7-command-prompt-wont-cd-into-a-network-mapped-drive Windows 7: Command Prompt won't CD into a network mapped drive [duplicate]]
 +
: <tt>cd</tt> is primarily for changing directories, you're trying to change drives.
 +
::- From the command prompt type <tt>z:</tt> or <tt>cd /D z:</tt>
 +
 +
==== Console &amp; Command Line Tools ====
 +
* [http://mridgers.github.io/clink/ Clink]: Powerful Bash-style command line editing for <tt>cmd.exe</tt>
 +
: Overview: Clink combines the native Windows shell '''<tt>cmd.exe</tt>''' with the powerful command line editing features of the GNU Readline library, which provides rich completion, history, and line-editing capabilities. Readline is best known for its use in the well-known Unix shell Bash, the standard shell for Mac OS X and many Linux distributions.
 +
 +
* [http://cmder.net/ Cmder]
 +
: Portable console emulator for Windows. &#8220;All the magic is happening through [https://conemu.github.io/ ConEmu]. With enhancements from [https://mridgers.github.io/clink/ Clink].&#8221; Hat tip: [https://plus.google.com/+BenKeller42 Ben Keller]
 +
 +
* [https://conemu.github.io/ ConEmu]
 +
: ConEmu-Maximus5 is a Windows console emulator with tabs, which presents multiple consoles and simple GUI applications as one customizable GUI window with various features.
 +
 +
* QUESTION: [http://www.slant.co/topics/1552/~terminal-emulators-for-windows What are the best terminal emulators for Windows?]
 +
: Top Three: #1 [http://www.slant.co/topics/1552/viewpoints/1/~terminal-emulators-for-windows~cmder cmder] #2 [http://www.slant.co/topics/1552/viewpoints/2/~terminal-emulators-for-windows~conemu ConEmu] #3 [http://www.slant.co/topics/1552/viewpoints/6/~terminal-emulators-for-windows~babun Babun]. Many others listed.
  
 
==== Generate File List ====
 
==== Generate File List ====
Line 44: Line 86:
 
: Example: <code>C:\Users\me\Downloads\MyFolder> <span style="color:DarkOrange">dir /b > filelist.txt</span></code>
 
: Example: <code>C:\Users\me\Downloads\MyFolder> <span style="color:DarkOrange">dir /b > filelist.txt</span></code>
 
:: (The text in orange shows the command used once you've navigated into the directory from which you want to generate the list of file names.)
 
:: (The text in orange shows the command used once you've navigated into the directory from which you want to generate the list of file names.)
 +
 +
* [http://www.howtogeek.com/98064/how-to-print-or-save-a-directory-listing-to-a-file/ How to Print or Save a Directory Listing to a File]
 +
 +
* [http://stackoverflow.com/questions/23228983/batch-file-list-files-in-directory-only-filenames Batch File; List files in directory, only filenames?]
  
 
* [http://stackoverflow.com/questions/15165295/a-powershell-script-to-list-all-files-and-folders-within-a-directory A PowerShell script to list all files and folders within a directory]
 
* [http://stackoverflow.com/questions/15165295/a-powershell-script-to-list-all-files-and-folders-within-a-directory A PowerShell script to list all files and folders within a directory]
Line 51: Line 97:
 
: Works with [[wikipedia:Command Prompt|cmd.exe]], but doesn't seem to work with [[wikipedia:Windows PowerShell|Windows PowerShell]].
 
: Works with [[wikipedia:Command Prompt|cmd.exe]], but doesn't seem to work with [[wikipedia:Windows PowerShell|Windows PowerShell]].
  
=== Bulk Rename Files ===
+
==== Generate Folder List (No Files, Just Directories and Sub-Directories) ====
* [http://www.howtogeek.com/111859/how-to-batch-rename-files-in-windows-4-ways-to-rename-multiple-files/ How to Batch Rename Files in Windows: 4 Ways to Rename Multiple Files]
+
* [http://stackoverflow.com/questions/16078421/how-do-i-get-a-list-of-folders-and-subfolders-without-the-files How do i get a list of folders and subfolders without the files]
: Bottom line: use this tool: [http://www.bulkrenameutility.co.uk/Download.php Bulk Rename Utility] (Windows only.)
+
: Try This: <code>C:\Users\me\Downloads\MyFolder> <span style="color:DarkOrange">dir /s /b /o:n /ad > folderlist.txt</span></code>
 +
 
 +
== Data Analysis Tools ==
 +
Moved content to [[Data Analysis]].
 +
 
 +
== Databases ==
 +
* [http://www.tutorialspoint.com/mysql/mysql-database-export.htm MySQL Database Export - Backup Methods]
 +
: Includes Section: '''Copying Tables or Databases to Another Host''':
 +
:: (You can) send the output of mysqldump directly over the network to the remote MySQL server. If you can connect to both servers from the host where source database resides, use this command (Make sure you have access on both the servers):
 +
:::<code>$ mysqldump -u root -p database_name \</code>:
 +
::::<code>| mysql -h other-host.com database_name</code>
 +
 
 +
== Educate Yourself ==
 +
''Also See: [[Data Analysis#Learn_Data_Science]]''
 +
=== Learn to Code ===
 +
* [http://www.labnol.org/internet/learn-coding-online/28537/ The Best Websites to Learn Coding Online] - Amit Agarwal, ''Digital Inspiration'', Jan 12 2015
 +
: The ''Learn to Code'' movement has picked up momentum worldwide and that is actually a good thing as even basic programming skills can have a major impact. If you can teach yourself how to write code, you gain a competitive edge over your peers, you can think more algorithmically and thus can tackle problems more efficiently.
 +
 
 +
* [http://www.propublica.org/nerds/item/new-years-resolution-learn-to-code New Year’s Resolution: Learn to Code] - by Lena Groeger, ''ProPublica'', Dec. 19, 2012, 2:51 p.m.
 +
: Lena Groeger: When I started learning to code, I was amazed by how much was out there: introductory videos, explanatory blog posts, tips and tricks and step-by-step guides. If you're a journalist who wants to make a news app or a student interested in learning to code, you have plenty of paths to choose from.
 +
 
 +
=== Multiple Codes ===
 +
* [http://www.codecademy.com/learn Codecademy]
 +
: Learn to code while building a project. Free online courses include: HTML &amp; CSS; jQuery; JavaScript; PHP; Python; Ruby; Web Projects; APIs
 +
 
 +
=== D3.js ===
 +
* [https://www.youtube.com/user/d3Vienno d3Vienno]
 +
: '''d3Vienno''' features a series of video tutorials, each about 10-12 minutes long, on using D3.js.
 +
 
 +
* [http://gisciencegroup.ucalgary.ca/engo500/texts/Interactive_Data_Visualization_for_the_Web.pdf Interactive Data Visualization for the Web: An Introduction to Designing with D3]
 +
 
 +
; D3 Tools
 +
* [http://nytimes.github.io/svg-crowbar/ SVG Crowbar]
 +
: A Chrome-specific bookmarklet that extracts SVG nodes and accompanying styles from an HTML document and downloads them as an SVG file—A file which you could open and edit in Adobe Illustrator, for instance. Because SVGs are resolution independent, it’s great for when you want to use web technologies to create documents that are meant to be printed (like, maybe on newsprint). It was created with d3.js in mind, but it should work fine no matter how you choose to generate your SVG.
 +
 
 +
=== Python ===
 +
* [http://www.analyticsvidhya.com/blog/2016/01/complete-tutorial-learn-data-science-python-scratch-2/ A Complete Tutorial to Learn Data Science with Python from Scratch]
 +
 
 +
* [https://www.datacamp.com/ DataCamp]
 +
: Learn Data Science Online: Master data analysis from the comfort of your browser, at your own pace, tailored to your needs and expertise. Whether you want to learn R, Python or Data Visualization, we want to help!
  
* Can't get [http://www.bulkrenameutility.co.uk/Download.php Bulk Rename Utility] to work? Use [http://ivanrf.com/en/portfolio-posts/massive-file-renamer/ Massive File Renamer] instead!
+
=== R ===
 +
* [http://www.analyticsvidhya.com/blog/2016/02/complete-tutorial-learn-data-science-scratch/ A Complete Tutorial to learn Data Science in R from Scratch]
  
==== Rename List of Files With Batch File ====
+
* [https://www.datacamp.com/ DataCamp]
It's easy to rename a group of files by running a [[wikipedia:Batch file|batch file]] (<tt>file.bat</tt>), configured something like this:
+
: Learn R & Become a Data Analyst
<pre>
+
 
rename "Old-File_001.jpg" "New-File_001.jpg"
+
* [http://swirlstats.com/ swirl - Learn R, in R.]
rename "Old-File_002.jpg" "New-File_002.jpg"
+
: swirl teaches you R programming and data science interactively, at your own pace, and right in the R console!
rename "Old-File_003.jpg" "New-File_003.jpg"
 
</pre>
 
Using Windows or DOS, just create your [[wikipedia:Batch file|batch file]] using the format shown above, and then double-click it to rename the files in the directory containing both your <tt>file.bat</tt> and files with the same names as those found in the "Old-File" (left) column of your <tt>file.bat</tt> file.
 
  
* [http://stackoverflow.com/questions/3808001/how-do-i-create-batch-file-to-rename-large-number-of-files-in-a-folder How do I create batch file to rename large number of files in a folder?]
+
=== SQL ===
: See this answer: http://stackoverflow.com/a/3808074
+
* [https://www.khanacademy.org/computing/computer-programming/sql Intro to SQL: Querying and managing data] ([[wikipedia:Khan Academy|Khan Academy]])
:: For help with using Regular Expressions in text file, see this answer: [http://stackoverflow.com/questions/28807534/regular-expresion-in-text-editor Regular expresion in text editor] ([[wikipedia:Sic|sic]])
+
: Learn how to use SQL to store, query, and manipulate data. SQL is a special-purpose programming language designed for managing data in a relational database, and is used by a huge number of apps and organizations.
  
==== Rename Multiple Folders / Directories With Batch File ====
+
* [http://sql.learncodethehardway.org/ Learn SQL The Hard Way (ALPHA)]
* [http://stackoverflow.com/questions/9271107/bat-file-for-renaming-multiple-folders .bat file for renaming multiple folders]
+
: This book will teach you the 80% of SQL you probably need to use it effectively, and will mix in concepts in data modeling at the same time. If you've been fumbling around building web, desktop, or mobile applications because you don't know SQL, then this book is for you. It is written for people with no prior database, programming, or SQL knowledge, but knowing at least one programming language will help.
: There are a couple of pretty good answers to this question; answers that explain how the regular expression written into the <tt>.bat</tt> file actually works.
 
  
 
== File Transfer ==
 
== File Transfer ==
Line 86: Line 168:
  
 
== Folder &amp; File Compression ==
 
== Folder &amp; File Compression ==
 +
* [https://www.youcompress.com/ Free Online File Compressor]
 +
: Compress MP4, MOV, MP3, PDF, PNG, JPG, JPEG, GIF files online for free. Reduce file size of videos, PDF documents, songs and images.
 +
:: [[User:Dave|Editor]]'s Note: Used this online converter to compress a video shot on iPhone 6.
 +
 
* [http://www.wikihow.com/Use-7Zip-to-Create-Multiple-Compressed-Folders-in-One-Go How to Use 7Zip to Create Multiple Compressed Folders in One Go]
 
* [http://www.wikihow.com/Use-7Zip-to-Create-Multiple-Compressed-Folders-in-One-Go How to Use 7Zip to Create Multiple Compressed Folders in One Go]
 
: Example: <code>for /d %%X in (*) do "c:\Program Files\7-Zip\7z.exe" a "%%X.zip" "%%X\"</code>
 
: Example: <code>for /d %%X in (*) do "c:\Program Files\7-Zip\7z.exe" a "%%X.zip" "%%X\"</code>
Line 92: Line 178:
 
: To compress a folder without using any particular compression software.
 
: To compress a folder without using any particular compression software.
 
[[File:MacScreenshots.PNG|500px|thumb|link=http://apple.stackexchange.com/questions/33906/alternative-to-windows-snipping-tool-for-mac-osx|Getting screenshots from a Mac.]]
 
[[File:MacScreenshots.PNG|500px|thumb|link=http://apple.stackexchange.com/questions/33906/alternative-to-windows-snipping-tool-for-mac-osx|Getting screenshots from a Mac.]]
== Print Screen / Screen Grabs / Screen Shots ==
 
* [[wikipedia:Print screen|Print Screen]]
 
: In [[wikipedia:Microsoft Windows|Microsoft Windows]], pressing <code>Prt Scr</code> will capture the entire screen, while pressing the <code>[[wikipedia:Alt key|Alt]]</code> key in combination with <code>Prt Scr</code> will capture the currently selected window.
 
  
; Using Ubuntu Linux
+
== [[wikipedia:Internet Relay Chat|Internet Relay Chat]] ([[wikipedia:Internet Relay Chat|IRC]]) Resources ==
* [http://www.onlyubuntu.com/2014/01/shutter-for-ubuntu-similar-to-windows-snipping-tool.html Shutter for Ubuntu similar to Windows Snipping Tool]
+
=== IRC in the Cloud ===
 +
* [https://webchat.freenode.net/ Connect - freenode Web IRC]
 +
: Legacy app. Super simple interface.
  
; Using Mac OS
+
* [https://kiwiirc.com/ Kiwi IRC]
* [http://apple.stackexchange.com/questions/33906/alternative-to-windows-snipping-tool-for-mac-osx Alternative to Windows Snipping Tool for Mac OSX]
+
: KiwiIRC makes Web IRC easy. A hand-crafted IRC client that you can enjoy. Designed to be used easily and freely.
* [http://apple.blogoverflow.com/2012/02/taking-screenshots-is-a-snap/ Taking Screenshots is a Snap]
 
  
; Using Windows
+
== Maintenance ==
* [http://windows.microsoft.com/en-us/windows7/products/features/snipping-tool Snipping Tool]
+
=== Dual Boot ===
 +
* [http://lifehacker.com/5403100/dual-boot-windows-7-and-ubuntu-in-perfect-harmony Dual-Boot Windows 7 and Ubuntu in Perfect Harmony]
  
== Regular Expressions ==
+
=== Boot Disks ===
* [[wikipedia:Regular expression|Regular expression]] (Wikipedia)
+
* [http://lifehacker.com/5991848/how-to-boot-from-a-cd-or-usb-drive-on-any-pc How to Boot From a CD or USB Drive on Any PC]
: In theoretical computer science and formal language theory, a regular expression (abbreviated <tt>regex</tt> or <tt>regexp</tt> and sometimes called a ''rational expression'') is a sequence of characters that forms a search pattern, mainly for use in pattern matching with strings, or string matching, i.e. "find and replace"-like operations.
 
  
=== RegEx Tutorials ===
+
* [http://rufus.akeo.ie/ Rufus]
* [http://www.regular-expressions.info/tutorial.html Regular Expressions Tutorial: Learn How to Use and Get The Most out of Regular Expressions]
+
: Rufus is an utility that helps format and create bootable USB flash drives, such as USB keys/pendrives, memory sticks, etc.
: Any non-trivial <tt>regex</tt> looks daunting to anybody not familiar with them. But with just a bit of experience, you will soon be able to craft your own regular expressions like you have never done anything else.
 
  
=== RegEx Tools ===
+
=== Network Issues ===
* [https://regex101.com Regex101: Online regex tester and debugger: JavaScript, Python, PHP, and PCRE]
+
* [http://www.howtosolutions.net/2013/06/fixing-slow-sending-or-receiving-of-files-through-lan-network-using-windows/ Local Area Network : How to fix slow LAN transfer speed of files in Windows]
: Regex101 allows you to create, debug, test and have your expressions explained for PHP, PCRE, JavaScript and Python. The website also features a community where you can share useful expressions.
+
: Post reviews various "fixes" found all over the web, and which "fix" actually worked for the post's author.
  
* [http://www.regexr.com/ RegExr: Learn, Build, & Test RegEx]
+
* [http://www.richard-slater.co.uk/archives/2009/10/23/change-your-mtu-under-vista-windows-7-or-windows-8/ Change your MTU under Vista, Windows 7 or Windows 8]
: Regular expression tester with syntax highlighting, contextual help, video tutorial, reference, and searchable community patterns.
+
: Path MTU Discovery (PMTUD) in Windows just doesn’t seem to figure out the MTU for a given path. So Windows uses the default. For the most part this doesn’t affect anyone. But failure of PMTUD will result in some websites not loading correctly, having trouble connecting to normally reliable online services and general Internet weirdness.
  
* [http://pythex.org/ Pythex: a Python regular expression editor]
+
== Print Screen / Screen Grabs / Screen Shots ==
: Pythex is a real-time regular expression editor for Python, a quick way to test your regular expressions.
+
* [[wikipedia:Print screen|Print Screen]]
 +
: In [[wikipedia:Microsoft Windows|Microsoft Windows]], pressing <code>Prt Scr</code> will capture the entire screen, while pressing the <code>[[wikipedia:Alt key|Alt]]</code> key in combination with <code>Prt Scr</code> will capture the currently selected window.
  
* [http://regexpal.com/ Regex Tester]
+
; iOS
: JavaScript regex tester. Highlights matches on the fly.
+
* [http://oneshot.link/ OneShot]
 +
: OneShot for iOS lets you highlight screenshots of text and share them to Twitter.
  
== Text Editors ==
+
; Linux (Ubuntu)
* [http://stackoverflow.com/questions/20533/mac-text-code-editor Mac text/code editor]
+
* [http://www.onlyubuntu.com/2014/01/shutter-for-ubuntu-similar-to-windows-snipping-tool.html Shutter for Ubuntu similar to Windows Snipping Tool]
  
== Text Extraction ==
+
; Mac OS
=== PDF Conversion ===
+
* [http://apple.stackexchange.com/questions/33906/alternative-to-windows-snipping-tool-for-mac-osx Alternative to Windows Snipping Tool for Mac OSX]
* [http://pdftotext.org/ pdftotext.org]
+
* [http://apple.blogoverflow.com/2012/02/taking-screenshots-is-a-snap/ Taking Screenshots is a Snap]
pdftotext.org is the best online service for easily extracting text from your PDF files. Conversion from PDF to TXT is really fast thanks to our in-browser conversion architecture. Your PDF files are never uploaded to the Internet, so even private PDF files are safe to convert with this service. The conversion is done locally in your browser – you can even convert when you are offline! There is no need for any registration or sign-up, and the service will always be free to use.
 
  
* [https://github.com/coolwanglu/pdf2htmlEX pdf2htmlEX]  
+
; Windows
: Convert PDF to HTML without losing text or format.
+
* [http://windows.microsoft.com/en-us/windows7/products/features/snipping-tool Snipping Tool]
  
* [http://stackoverflow.com/questions/6187250/pdf-text-extraction PDF TEXT Extraction]
+
== Regular Expressions ==
: Lists several options.
+
Moved content to [[Data Analysis]].
  
* [http://capture2text.sourceforge.net/ Capture2Text]
+
== Rename Files &amp; Folders ==
: Capture2Text enables users to do the following:
+
* [http://www.robvanderwoude.com/battech_rename.php Batch Techniques - Rename Files or Folders]
# Optical Character Recognition (OCR)
+
: Rename Files Using <tt>REN</tt> or <tt>RENAME</tt>
# Speech Recognition
+
::- <tt>RENAME [drive:][path]filename1 filename2</tt>
 +
::- <tt>REN [drive:][path]filename1 filename2</tt>
 +
: Rename Folders: You can rename folders with the <tt>MOVE</tt> command:
 +
::- <tt>MOVE d:\path\folder1 folder2</tt>
  
* [https://sourceforge.net/projects/doctotext/ SILVERCODERS DocToText]  
+
* [http://superuser.com/questions/16007/how-can-i-mass-rename-files How can I mass rename files?]
: Extracts plain text from documents in all popular formats.
 
  
* [https://sourceforge.net/projects/detexter/ Detexter]
+
* [http://www.labnol.org/software/tutorials/rename-multiple-files-bulk-excel-googl-docs/2481/ Rename Multiple Files Efficiently Using Excel or Google Docs]
: Detexter is an app designed to extract text from PDF files.
+
: To rename files in bulk more efficiently, you can either learn some complex shell scripting language (SED, AWK, Perl) or switch to something more simple--a spreadsheet.
  
=== Data Scrape ===
+
=== Bulk Rename Files ===
* [https://docs.google.com/a/evolvnet.com/document/d/18Q2THQvYCG2_n6nKVsZRHlaPG9iJ9NvLezOOQbEuAJs/edit?hl=en Almost Scraping: Web Scraping for Non-Programmers]
+
* [http://www.howtogeek.com/111859/how-to-batch-rename-files-in-windows-4-ways-to-rename-multiple-files/ How to Batch Rename Files in Windows: 4 Ways to Rename Multiple Files]
: Tools and tips compiled by journalists from PBS and Omaha World-Herald.
 
  
* [http://blog.scrapinghub.com/2014/01/18/open-source-at-scrapinghub/ Open Source at Scrapinghub]
+
* [http://www.bulkrenameutility.co.uk/Main_Intro.php Bulk Rename Utility] - GUI Interface (Windows only.)
: Scrapinghub's list of open source scraping projects.
+
* [http://www.bulkrenameutility.co.uk/Command.php Bulk Rename Command] - non-GUI, CMD Interface (Windows only.)
  
* [http://sitestalker.net/ Sitestalker]
+
* [http://www.antp.be/software/renamer Ant Renamer]
: Monitor website links with ease. Sitestalker supervises websites and notifies you when your desired content hits the web.Stop wasting your time constantly refreshing websites.
 
: Sitestalker is great for:
 
:: Finding jobs
 
:: Searching for an apartment
 
:: Getting the best bargains
 
:: Clipping
 
  
* [http://www.notprovided.eu/six-tools-web-scraping-use-data-journalism-creating-insightful-content/ Six tools for web scraping – To use for data journalism & creating insightful content]
+
* '''[http://ivanrf.com/en/portfolio-posts/massive-file-renamer/ Massive File Renamer]''': Confused by [http://www.bulkrenameutility.co.uk/Download.php Bulk Rename Utility]? Take a look at [http://ivanrf.com/en/portfolio-posts/massive-file-renamer/ Massive File Renamer] instead. Massive File Renamer is simpler to use, and is available in Linux, Mac and Windows versions.
: Tools for gathering data from public sources.
 
  
=== Text Search ===
+
=== Rename List of Files With Batch File ===
* [http://geekdadaji.com/ geekDadaji - A SEARCH INITIATIVE]
+
It's easy to rename a group of files by running a [[wikipedia:Batch file|batch file]] (<tt>file.bat</tt>), configured something like this:
: Makes tools to search text content, including:
+
<pre>rename "Old-File_001.jpg" "New-File_001.jpg"
# [https://sourceforge.net/projects/falcontextsearch/ FALCON - Text Search Java Project]: JSON based text search Java Project
+
rename "Old-File_002.jpg" "New-File_002.jpg"
# [https://sourceforge.net/projects/hawksearch/ HAWK - PDF Text Search Java Project]: Taking initiative for Document Text Search
+
rename "Old-File_003.jpg" "New-File_003.jpg"</pre>
 +
# Using a simple text editor (such as [[wikipedia:Notepad++|Notepad++]]), just create your [[wikipedia:Batch file|batch file]] using the format shown above.
 +
# Save the file as <tt>rename.bat</tt> (or similar name) in the same folder containing the files you want to rename.
 +
# Double-click your batch file (e.g. <tt>rename.bat</tt>) to rename the files to the new file name.
  
* [http://www.foolabs.com/xpdf/home.html Xpdf: A PDF Viewer for X]
+
=== Rename List of Folders With Batch File | Include Full Paths ===
: Xpdf is an open source viewer for Portable Document Format (PDF) files.
+
It's easy to rename a group of folders located in different parent directories by running a [[wikipedia:Batch file|batch file]] (<tt>file.bat</tt>), configured something like this:
: Windows installer: [http://www.compgeom.com/~piyush/scripts/scripts.html Short Programs/Scripts] (Look for the xpdf3.exe / poppler.exe links in left sidebar.)
+
<pre>MOVE "C:\Parent Directory One \Sub Directory\Old Folder Name" "C:\Parent Directory One \Sub Directory\New Folder Name"
 +
MOVE "C:\Parent Directory Two \Sub Directory\Old Folder Name" "C:\Parent Directory Two \Sub Directory\New Folder Name"
 +
MOVE "C:\Parent Directory Three \Sub Directory\Old Folder Name" "C:\Parent Directory Three \Sub Directory\New Folder Name"</pre>
  
== Educate Yourself ==
+
* [http://www.wikihow.com/Write-a-Batch-File How to Write a Batch File]
=== Learn to Code ===
+
: A batch file contains a series of DOS commands, and is commonly written to automate frequently performed tasks. Instead of typing the same commands over and over, you can simply double-click the batch file. Writing a batch file is easier than it looks; the difficult part is making sure that everything happens in the right order. Well-made batch files can save you a lot of time over the long run, especially if you deal in repetitive tasks.
* [http://www.labnol.org/internet/learn-coding-online/28537/ The Best Websites to Learn Coding Online] - Amit Agarwal, ''Digital Inspiration'', Jan 12 2015
 
: The ''Learn to Code'' movement has picked up momentum worldwide and that is actually a good thing as even basic programming skills can have a major impact. If you can teach yourself how to write code, you gain a competitive edge over your peers, you can think more algorithmically and thus can tackle problems more efficiently.
 
  
* [http://www.propublica.org/nerds/item/new-years-resolution-learn-to-code New Year’s Resolution: Learn to Code] - by Lena Groeger, ''ProPublica'', Dec. 19, 2012, 2:51 p.m.
+
* [http://stackoverflow.com/questions/3808001/how-do-i-create-batch-file-to-rename-large-number-of-files-in-a-folder How do I create batch file to rename large number of files in a folder?]
: Lena Groeger: When I started learning to code, I was amazed by how much was out there: introductory videos, explanatory blog posts, tips and tricks and step-by-step guides. If you're a journalist who wants to make a news app or a student interested in learning to code, you have plenty of paths to choose from.
+
: See this answer: http://stackoverflow.com/a/3808074
 +
:: For help with using Regular Expressions in text file, see this answer: [http://stackoverflow.com/questions/28807534/regular-expresion-in-text-editor Regular expresion in text editor] ([[wikipedia:Sic|sic]])
  
=== Multiple Codes ===
+
=== Rename Multiple Folders / Directories With Batch File ===
* [http://www.codecademy.com/learn Codecademy]
+
* [http://stackoverflow.com/questions/9271107/bat-file-for-renaming-multiple-folders .bat file for renaming multiple folders]
: Learn to code while building a project. Free online courses include: HTML &amp; CSS; jQuery; JavaScript; PHP; Python; Ruby; Web Projects; APIs
+
: There are a couple of pretty good answers to this question; answers that explain how the regular expression written into the <tt>.bat</tt> file actually works.
  
=== R ===
+
== Text Editors ==
* [https://www.datacamp.com/ DataCamp]
 
: Learn R & Become a Data Analyst
 
  
=== D3.js ===
+
=== Mac Text Editors ===
* [https://www.youtube.com/user/d3Vienno d3Vienno]
+
* [http://stackoverflow.com/questions/20533/mac-text-code-editor Mac text/code editor]
: '''d3Vienno''' features a series of video tutorials, each about 10-12 minutes long, on using D3.js.
 
  
* [http://gisciencegroup.ucalgary.ca/engo500/texts/Interactive_Data_Visualization_for_the_Web.pdf Interactive Data Visualization for the Web: An Introduction to Designing with D3]
+
=== Notepad++ ===
 +
* [http://stackoverflow.com/questions/15398202/find-and-replace-end-of-line-with-n-verbatim Notepad ++ Find & Replace Characters at End of Line]
 +
: If you go into Notepad++ and go to Edit>EOL Conversion, if allows you to convert from the current EOL to Unix-style, Windows-style, or Mac-style.
 +
:: Unix is <tt>\n</tt> only
 +
:: Windows is <tt>\r\n</tt>
 +
:: Mac is <tt>\r</tt> only
  
; D3 Tools
+
== Text Extraction ==
* [http://nytimes.github.io/svg-crowbar/ SVG Crowbar]
+
Moved content to [[Data Analysis]].
: A Chrome-specific bookmarklet that extracts SVG nodes and accompanying styles from an HTML document and downloads them as an SVG file—A file which you could open and edit in Adobe Illustrator, for instance. Because SVGs are resolution independent, it’s great for when you want to use web technologies to create documents that are meant to be printed (like, maybe on newsprint). It was created with d3.js in mind, but it should work fine no matter how you choose to generate your SVG.
 
 
 
== Data Analysis Tools ==
 
* [http://d3js.org/ D3.js - Data-Driven Documents]
 
: '''D3.js''' is a JavaScript library for manipulating documents based on data. D3 helps you bring data to life using HTML, SVG and CSS. D3’s emphasis on web standards gives you the full capabilities of modern browsers without tying yourself to a proprietary framework, combining powerful visualization components and a data-driven approach to DOM manipulation.
 
 
 
* [https://www.rstudio.com/ide/download/ Download RStudio]
 
: Take control of your R code. RStudio is the premier integrated development environment for R. It is available in open source and commercial editions and runs on the desktop (Windows, Mac, and Linux) or over the web with RStudio Server. Download RStudio (for Windows, Mac, or Linux).
 
 
 
* [http://openrefine.org/ OpenRefine] (Formerly [http://code.google.com/p/google-refine/Google Refine].)
 
: '''[[wikipedia:OpenRefine|Open Refine]]''' is a standalone open source desktop application for data cleanup and transformation to other formats, the activity known as [[wikipedia:Data wrangling|data wrangling]]. It is similar to [[wikipedia:Spreadsheet|spreadsheet]] applications (and can work with spreadsheet file formats), however, it behaves more like a database.
 
 
 
* [http://vis.stanford.edu/wrangler/ Data Wrangler] (Stanford Visualization Group)
 
: Wrangler allows interactive transformation of messy, real-world data into the data tables analysis tools expect. Export data for use in Excel, R, Tableau, Protovis, ...
 
 
 
* [http://htsql.org/ HTSQL&mdash;A Database Query Language]
 
: HTSQL is designed for data analysts and other ''accidental programmers'' who have complex business inquiries to solve and need a productive tool to write and share database queries. HTSQL is ''free and open source'' software.
 
 
 
* [http://www.cc.gatech.edu/gvu/ii/jigsaw/ Jigsaw: Visual Analytics for Exploring and Understanding Document Collections]
 
: Jigsaw is a visual analytics system to help analysts and researchers better explore, analyze, and make sense of such document collections.
 
  
 
== Investigative Reporting; Journalism; General Research ==
 
== Investigative Reporting; Journalism; General Research ==
* [http://www.ire.org/ Investigative Reporters and Editors] ([http://www.ire.org/ IRE])
+
Moved content to [[Journalism Tools]].
: Useful IRE Resources:
 
::- [http://www.ire.org/nicar/nicar-net-tour/ NICAR Net Tour] - The [http://www.ire.org/nicar/ National Institute for Computer-Assisted Reporting] ([http://www.ire.org/nicar/ NICAR]) is an [http://www.ire.org/ IRE] program.
 
::- [http://www.ire.org/nicar/analysis-jobs/ Analysis jobs by NICAR] - Names the media organizations [http://www.ire.org/nicar/ NICAR] has worked for, and lists kinds of analysis jobs [http://www.ire.org/nicar/ NICAR] has done.
 
  
== Maintenance ==
+
== See Also ==
=== Dual Boot ===
+
== References ==
* [http://lifehacker.com/5403100/dual-boot-windows-7-and-ubuntu-in-perfect-harmony Dual-Boot Windows 7 and Ubuntu in Perfect Harmony]
+
{{Reflist}}
 
 
=== Boot Disks ===
 
* [http://lifehacker.com/5991848/how-to-boot-from-a-cd-or-usb-drive-on-any-pc How to Boot From a CD or USB Drive on Any PC]
 
 
 
* [http://rufus.akeo.ie/ Rufus]
 
: Rufus is an utility that helps format and create bootable USB flash drives, such as USB keys/pendrives, memory sticks, etc.
 
  
=== Network Issues ===
+
{{Additional Resource Wiki Pages}}
* [http://www.howtosolutions.net/2013/06/fixing-slow-sending-or-receiving-of-files-through-lan-network-using-windows/ Local Area Network : How to fix slow LAN transfer speed of files in Windows]
 
: Post reviews various "fixes" found all over the web, and which "fix" actually worked for the post's author.
 
 
 
* [http://www.richard-slater.co.uk/archives/2009/10/23/change-your-mtu-under-vista-windows-7-or-windows-8/ Change your MTU under Vista, Windows 7 or Windows 8]
 
: Path MTU Discovery (PMTUD) in Windows just doesn’t seem to figure out the MTU for a given path. So Windows uses the default. For the most part this doesn’t affect anyone. But failure of PMTUD will result in some websites not loading correctly, having trouble connecting to normally reliable online services and general Internet weirdness.
 
 
 
== See Also ==
 
* [[Office Productivity Hacks]]
 
* [[Spreadsheet Tricks]]
 
* [[Social Networking Tips]]
 
* [[User:Dave/Web Hack Notes (Non-Wiki)]]
 

Latest revision as of 19:36, 30 July 2019

Command Line

Sometimes referred to as a command script, a command language is a language used for executing a series of commands that would otherwise be executed at the prompt. A good example of a command language is Microsoft Windows batch files. Although command languages are useful for executing a series of commands, their functionality is limited to what is available at the command line which can make them easier to learn.
Quick super fast course in using the command line. It is intended to be done rapidly in about a day or two, and not meant to teach you advanced shell usage.

Bash & Linux Commands

Got a bunch of .tar.gz files you want to unpack onto a server at the same time. Then this tutorial is for you.

WGET

Using PowerShell (Among other useful options listed at this resource.):
WinWGet is a GUI (Graphical User Interface) for Wget. It is FREE. It will keep track of your downloads - add, clone, edit, delete jobs.
GNU Wget is a free network utility to retrieve files from the World Wide Web using HTTP and FTP, the two most widely used Internet protocols. It works non-interactively, thus enabling work in the background, after having logged off.
Say you want to backup your blog or create a local copy of an entire directory of a web site for archiving or reading later. The command: wget -m http://website.tld
Tips for mirroring specific directories, update only changed files, etc.
Download files using curl or wget. This addon generates curl/wget commands that emulate the request as though it's coming from your browser allowing you to download protected files directly to a separate machine (e.g. server).

Windows Command Line

Cmdlets are the heart-and-soul of Windows PowerShell, Microsoft's latest command shell/scripting language.
Robocopy: A robust file copy command for the Windows command line.
Each command is linked to more info about the particular command.
The xcopy command is a Command Prompt command used to copy one or more files and/or folders from one location to another location.
This question is answered in numerous ways. Many of the answers point to useful utilities to accomplish find-and-replace.

Command Prompt

  1. Open desired directory in windows explorer.
  2. Hold down shift and right click.
  3. Select open command window here from menu.
Mounting shared drives and connecting to remote resources is something you can easily do from the Windows GUI. With our quick guide to the command prompt, however, you can more easily automate large tasks.
cd is primarily for changing directories, you're trying to change drives.
- From the command prompt type z: or cd /D z:

Console & Command Line Tools

  • Clink: Powerful Bash-style command line editing for cmd.exe
Overview: Clink combines the native Windows shell cmd.exe with the powerful command line editing features of the GNU Readline library, which provides rich completion, history, and line-editing capabilities. Readline is best known for its use in the well-known Unix shell Bash, the standard shell for Mac OS X and many Linux distributions.
Portable console emulator for Windows. “All the magic is happening through ConEmu. With enhancements from Clink.” Hat tip: Ben Keller
ConEmu-Maximus5 is a Windows console emulator with tabs, which presents multiple consoles and simple GUI applications as one customizable GUI window with various features.
Top Three: #1 cmder #2 ConEmu #3 Babun. Many others listed.

Generate File List

Example: C:\Users\me\Downloads\MyFolder> dir /b > filelist.txt
(The text in orange shows the command used once you've navigated into the directory from which you want to generate the list of file names.)
This tutorial contains several working answers for using Windows PowerShell to list files and folders.
Works with cmd.exe, but doesn't seem to work with Windows PowerShell.

Generate Folder List (No Files, Just Directories and Sub-Directories)

Try This: C:\Users\me\Downloads\MyFolder> dir /s /b /o:n /ad > folderlist.txt

Data Analysis Tools

Moved content to Data Analysis.

Databases

Includes Section: Copying Tables or Databases to Another Host:
(You can) send the output of mysqldump directly over the network to the remote MySQL server. If you can connect to both servers from the host where source database resides, use this command (Make sure you have access on both the servers):
$ mysqldump -u root -p database_name \:
| mysql -h other-host.com database_name

Educate Yourself

Also See: Data Analysis#Learn_Data_Science

Learn to Code

The Learn to Code movement has picked up momentum worldwide and that is actually a good thing as even basic programming skills can have a major impact. If you can teach yourself how to write code, you gain a competitive edge over your peers, you can think more algorithmically and thus can tackle problems more efficiently.
Lena Groeger: When I started learning to code, I was amazed by how much was out there: introductory videos, explanatory blog posts, tips and tricks and step-by-step guides. If you're a journalist who wants to make a news app or a student interested in learning to code, you have plenty of paths to choose from.

Multiple Codes

Learn to code while building a project. Free online courses include: HTML & CSS; jQuery; JavaScript; PHP; Python; Ruby; Web Projects; APIs

D3.js

d3Vienno features a series of video tutorials, each about 10-12 minutes long, on using D3.js.
D3 Tools
A Chrome-specific bookmarklet that extracts SVG nodes and accompanying styles from an HTML document and downloads them as an SVG file—A file which you could open and edit in Adobe Illustrator, for instance. Because SVGs are resolution independent, it’s great for when you want to use web technologies to create documents that are meant to be printed (like, maybe on newsprint). It was created with d3.js in mind, but it should work fine no matter how you choose to generate your SVG.

Python

Learn Data Science Online: Master data analysis from the comfort of your browser, at your own pace, tailored to your needs and expertise. Whether you want to learn R, Python or Data Visualization, we want to help!

R

Learn R & Become a Data Analyst
swirl teaches you R programming and data science interactively, at your own pace, and right in the R console!

SQL

Learn how to use SQL to store, query, and manipulate data. SQL is a special-purpose programming language designed for managing data in a relational database, and is used by a huge number of apps and organizations.
This book will teach you the 80% of SQL you probably need to use it effectively, and will mix in concepts in data modeling at the same time. If you've been fumbling around building web, desktop, or mobile applications because you don't know SQL, then this book is for you. It is written for people with no prior database, programming, or SQL knowledge, but knowing at least one programming language will help.

File Transfer

File Transfer Clients for Windows Mac

Lists several clients recommended for interoperating with OpenSSH from Mac OS machines. Note that Mac OS X includes OpenSSH by default.
SSH Clients for Windows, Mac, and Unix
Libre FTP, SFTP, WebDAV, S3 & OpenStack Swift browser for Mac and Windows.

Folder & File Compression

Compress MP4, MOV, MP3, PDF, PNG, JPG, JPEG, GIF files online for free. Reduce file size of videos, PDF documents, songs and images.
Editor's Note: Used this online converter to compress a video shot on iPhone 6.
Example: for /d %%X in (*) do "c:\Program Files\7-Zip\7z.exe" a "%%X.zip" "%%X\"
To compress a folder without using any particular compression software.
Getting screenshots from a Mac.

Internet Relay Chat (IRC) Resources

IRC in the Cloud

Legacy app. Super simple interface.
KiwiIRC makes Web IRC easy. A hand-crafted IRC client that you can enjoy. Designed to be used easily and freely.

Maintenance

Dual Boot

Boot Disks

Rufus is an utility that helps format and create bootable USB flash drives, such as USB keys/pendrives, memory sticks, etc.

Network Issues

Post reviews various "fixes" found all over the web, and which "fix" actually worked for the post's author.
Path MTU Discovery (PMTUD) in Windows just doesn’t seem to figure out the MTU for a given path. So Windows uses the default. For the most part this doesn’t affect anyone. But failure of PMTUD will result in some websites not loading correctly, having trouble connecting to normally reliable online services and general Internet weirdness.

Print Screen / Screen Grabs / Screen Shots

In Microsoft Windows, pressing Prt Scr will capture the entire screen, while pressing the Alt key in combination with Prt Scr will capture the currently selected window.
iOS
OneShot for iOS lets you highlight screenshots of text and share them to Twitter.
Linux (Ubuntu)
Mac OS
Windows

Regular Expressions

Moved content to Data Analysis.

Rename Files & Folders

Rename Files Using REN or RENAME
- RENAME [drive:][path]filename1 filename2
- REN [drive:][path]filename1 filename2
Rename Folders: You can rename folders with the MOVE command:
- MOVE d:\path\folder1 folder2
To rename files in bulk more efficiently, you can either learn some complex shell scripting language (SED, AWK, Perl) or switch to something more simple--a spreadsheet.

Bulk Rename Files

Rename List of Files With Batch File

It's easy to rename a group of files by running a batch file (file.bat), configured something like this:

rename "Old-File_001.jpg" "New-File_001.jpg"
rename "Old-File_002.jpg" "New-File_002.jpg"
rename "Old-File_003.jpg" "New-File_003.jpg"
  1. Using a simple text editor (such as Notepad++), just create your batch file using the format shown above.
  2. Save the file as rename.bat (or similar name) in the same folder containing the files you want to rename.
  3. Double-click your batch file (e.g. rename.bat) to rename the files to the new file name.

Rename List of Folders With Batch File | Include Full Paths

It's easy to rename a group of folders located in different parent directories by running a batch file (file.bat), configured something like this:

MOVE "C:\Parent Directory One \Sub Directory\Old Folder Name" "C:\Parent Directory One \Sub Directory\New Folder Name"
MOVE "C:\Parent Directory Two \Sub Directory\Old Folder Name" "C:\Parent Directory Two \Sub Directory\New Folder Name"
MOVE "C:\Parent Directory Three \Sub Directory\Old Folder Name" "C:\Parent Directory Three \Sub Directory\New Folder Name"
A batch file contains a series of DOS commands, and is commonly written to automate frequently performed tasks. Instead of typing the same commands over and over, you can simply double-click the batch file. Writing a batch file is easier than it looks; the difficult part is making sure that everything happens in the right order. Well-made batch files can save you a lot of time over the long run, especially if you deal in repetitive tasks.
See this answer: http://stackoverflow.com/a/3808074
For help with using Regular Expressions in text file, see this answer: Regular expresion in text editor (sic)

Rename Multiple Folders / Directories With Batch File

There are a couple of pretty good answers to this question; answers that explain how the regular expression written into the .bat file actually works.

Text Editors

Mac Text Editors

Notepad++

If you go into Notepad++ and go to Edit>EOL Conversion, if allows you to convert from the current EOL to Unix-style, Windows-style, or Mac-style.
Unix is \n only
Windows is \r\n
Mac is \r only

Text Extraction

Moved content to Data Analysis.

Investigative Reporting; Journalism; General Research

Moved content to Journalism Tools.

See Also

References

Additional Resource Wiki Pages

HomeDave