1
0
Fork 0
mirror of https://github.com/tldr-pages/tldr.git synced 2025-06-07 21:46:03 +02:00

Refactor: change "folder" to "directory" where needed.

This commit fixes every instance in which the word "folder" is
incorrectly used instead of "directory".
This commit is contained in:
Marco Bonelli 2019-02-11 19:00:49 +01:00 committed by Agniva De Sarker
parent 2484529a83
commit 2599a6de48
65 changed files with 202 additions and 202 deletions

View file

@ -10,7 +10,7 @@
`7z a {{archivio_criptato.7z}} -p {{password}} -mhe {{archivio.7z}}` `7z a {{archivio_criptato.7z}} -p {{password}} -mhe {{archivio.7z}}`
- Estrai un archivio mantenendo la gerarchia delle cartelle: - Estrai un archivio mantenendo la gerarchia delle directory:
`7z x {{archivio.7z}}` `7z x {{archivio.7z}}`

View file

@ -7,7 +7,7 @@
`7zr a {{archivio.7z}} {{percorso/a/file_o_directory}}` `7zr a {{archivio.7z}} {{percorso/a/file_o_directory}}`
- Estrai un archivio mantenendo la gerarchia delle cartelle: - Estrai un archivio mantenendo la gerarchia delle directory:
`7zr x {{archivio.7z}}` `7zr x {{archivio.7z}}`

View file

@ -18,13 +18,13 @@
`adb install -r {{path/to/file.apk}}` `adb install -r {{path/to/file.apk}}`
- Copy a file/folder from the target device: - Copy a file/directory from the target device:
`adb pull {{path/to/device_file_or_folder}} {{path/to/local_destination_folder}}` `adb pull {{path/to/device_file_or_directory}} {{path/to/local_destination_directory}}`
- Copy a file/folder to the target device: - Copy a file/directory to the target device:
`adb push {{path/to/local_file_or_folder}} {{path/to/device_destination_folder}}` `adb push {{path/to/local_file_or_directory}} {{path/to/device_destination_directory}}`
- Get a list of connected devices: - Get a list of connected devices:

View file

@ -3,17 +3,17 @@
> A cross-platform pluggable text editor. > A cross-platform pluggable text editor.
> Plugins are managed by `apm`. > Plugins are managed by `apm`.
- Open a file or folder: - Open a file or directory:
`atom {{path/to/file_or_folder}}` `atom {{path/to/file_or_directory}}`
- Open a file or folder in a new window: - Open a file or directory in a new window:
`atom -n {{path/to/file_or_folder}}` `atom -n {{path/to/file_or_directory}}`
- Open a file or folder in an existing window: - Open a file or directory in an existing window:
`atom --add {{path/to/file_or_folder}}` `atom --add {{path/to/file_or_directory}}`
- Open atom in safe mode (does not load any additional packages): - Open atom in safe mode (does not load any additional packages):

View file

@ -6,17 +6,17 @@
`aws s3 ls {{bucket_name}}` `aws s3 ls {{bucket_name}}`
- Sync files and folders from local to bucket: - Sync files and directories from local to bucket:
`aws s3 sync {{path/to/files}} s3://{{bucket_name}}` `aws s3 sync {{path/to/files}} s3://{{bucket_name}}`
- Sync files and folders from bucket to local: - Sync files and directories from bucket to local:
`aws s3 sync s3://{{bucket_name}} {{path/to/target}}` `aws s3 sync s3://{{bucket_name}} {{path/to/target}}`
- Sync files and folders with exclusions: - Sync files and directories with exclusions:
`aws s3 sync {{path/to/files}} s3://{{bucket_name}} --exclude {{path/to/file}} --exclude {{path/to/folder}}/*` `aws s3 sync {{path/to/files}} s3://{{bucket_name}} --exclude {{path/to/file}} --exclude {{path/to/directory}}/*`
- Remove file from bucket: - Remove file from bucket:

View file

@ -6,15 +6,15 @@
`l` `l`
- Save the current folder as "bookmark_name": - Save the current directory as "bookmark_name":
`s {{bookmark_name}}` `s {{bookmark_name}}`
- Go to a bookmarked folder: - Go to a bookmarked directory:
`g {{bookmark_name}}` `g {{bookmark_name}}`
- Print a bookmarked folder's contents: - Print a bookmarked directory's contents:
`p {{bookmark_name}}` `p {{bookmark_name}}`

View file

@ -11,13 +11,13 @@
`blender -b {{filename}}.blend -o //{{render/frame_###.png}} -a` `blender -b {{filename}}.blend -o //{{render/frame_###.png}} -a`
- Render the 10th frame of an animation as a single image, saved to an existing folder (absolute path): - Render the 10th frame of an animation as a single image, saved to an existing directory (absolute path):
`blender -b {{filename}}.blend -o {{/path/to/output_folder}} -f {{10}}` `blender -b {{filename}}.blend -o {{/path/to/output_directory}} -f {{10}}`
- Render the second last frame in an animation as a JPEG image, saved to an existing folder (relative path): - Render the second last frame in an animation as a JPEG image, saved to an existing directory (relative path):
`blender -b {{filename}}.blend -o //{{output_folder}} -F {{JPEG}} -f {{-2}}` `blender -b {{filename}}.blend -o //{{output_directory}} -F {{JPEG}} -f {{-2}}`
- Render the animation of a specific scene, starting at frame 10 and ending at frame 500: - Render the animation of a specific scene, starting at frame 10 and ending at frame 500:

View file

@ -5,27 +5,27 @@
- Initialise a (local) repository: - Initialise a (local) repository:
`borg init {{/path/to/repo_folder}}` `borg init {{/path/to/repo_directory}}`
- Backup a folder into the repository, creating an archive called "Monday": - Backup a directory into the repository, creating an archive called "Monday":
`borg create --progress {{/path/to/repo_folder}}::{{Monday}} {{/path/to/source_folder}}` `borg create --progress {{/path/to/repo_directory}}::{{Monday}} {{/path/to/source_directory}}`
- List all archives in a repository: - List all archives in a repository:
`borg list {{/path/to/repo_folder}}` `borg list {{/path/to/repo_directory}}`
- Extract a specific folder from the "Monday" archive in a remote repository, excluding all *.ext files: - Extract a specific directory from the "Monday" archive in a remote repository, excluding all *.ext files:
`borg extract {{user}}@{{host}}:{{/path/to/repo_folder}}::{{Monday}} {{path/to/target_folder}} --exclude '{{*.ext}}'` `borg extract {{user}}@{{host}}:{{/path/to/repo_directory}}::{{Monday}} {{path/to/target_directory}} --exclude '{{*.ext}}'`
- Prune a repository by deleting all archives older than 7 days, listing changes: - Prune a repository by deleting all archives older than 7 days, listing changes:
`borg prune --keep-within {{7d}} --list {{/path/to/repo_folder}}` `borg prune --keep-within {{7d}} --list {{/path/to/repo_directory}}`
- Mount a repository as a FUSE filesystem: - Mount a repository as a FUSE filesystem:
`borg mount {{/path/to/repo_folder}}::{{Monday}} {{/path/to/mountpoint}}` `borg mount {{/path/to/repo_directory}}::{{Monday}} {{/path/to/mountpoint}}`
- Display help on creating archives: - Display help on creating archives:

View file

@ -6,13 +6,13 @@
`bup -d {{path/to/repository}} init` `bup -d {{path/to/repository}} init`
- Prepare a given folder before taking a backup: - Prepare a given directory before taking a backup:
`bup -d {{path/to/repository}} index {{path/to/folder}}` `bup -d {{path/to/repository}} index {{path/to/directory}}`
- Backup a folder to the repository: - Backup a directory to the repository:
`bup -d {{path/to/repository}} save -n {{backup_name}} {{path/to/folder}}` `bup -d {{path/to/repository}} save -n {{backup_name}} {{path/to/directory}}`
- Show the backup snapshots currently stored in the repository: - Show the backup snapshots currently stored in the repository:

View file

@ -1,14 +1,14 @@
# chgrp # chgrp
> Change group ownership of files and folders. > Change group ownership of files and directories.
- Change the owner group of a file/directory: - Change the owner group of a file/directory:
`chgrp {{group}} {{path/to/file_or_directory}}` `chgrp {{group}} {{path/to/file_or_directory}}`
- Recursively change the owner group of a folder and its contents: - Recursively change the owner group of a directory and its contents:
`chgrp -R {{group}} {{path/to/folder}}` `chgrp -R {{group}} {{path/to/directory}}`
- Change the owner group of a symbolic link: - Change the owner group of a symbolic link:

View file

@ -1,6 +1,6 @@
# chown # chown
> Change user and group ownership of files and folders. > Change user and group ownership of files and directories.
- Change the owner user of a file/directory: - Change the owner user of a file/directory:
@ -10,9 +10,9 @@
`chown {{user}}:{{group}} {{path/to/file_or_directory}}` `chown {{user}}:{{group}} {{path/to/file_or_directory}}`
- Recursively change the owner of a folder and its contents: - Recursively change the owner of a directory and its contents:
`chown -R {{user}} {{path/to/folder}}` `chown -R {{user}} {{path/to/directory}}`
- Change the owner of a symbolic link: - Change the owner of a symbolic link:

View file

@ -3,11 +3,11 @@
> Cross-platform build system generator. > Cross-platform build system generator.
> It generates Makefiles, Visual Studio projects or others, depending on the target system. > It generates Makefiles, Visual Studio projects or others, depending on the target system.
- Generate a Makefile and use it to compile a project in the same folder as the source: - Generate a Makefile and use it to compile a project in the same directory as the source:
`cmake && make` `cmake && make`
- Generate a Makefile and use it to compile a project in a separate "build" folder (out-of-source build): - Generate a Makefile and use it to compile a project in a separate "build" directory (out-of-source build):
`cmake -H. -B{{build}} && make -C {{build}}` `cmake -H. -B{{build}} && make -C {{build}}`

View file

@ -1,27 +1,27 @@
# cp # cp
> Copy files and folders. > Copy files and directories.
- Copy a file to another location: - Copy a file to another location:
`cp {{path/to/file.ext}} {{path/to/copy.ext}}` `cp {{path/to/file.ext}} {{path/to/copy.ext}}`
- Copy a file into another folder, keeping the filename: - Copy a file into another directory, keeping the filename:
`cp {{path/to/file.ext}} {{path/to/target_parent_folder}}` `cp {{path/to/file.ext}} {{path/to/target_parent_directory}}`
- Copy a folder recursively to another location: - Copy a directory recursively to another location:
`cp -r {{path/to/folder}} {{path/to/copy}}` `cp -r {{path/to/directory}} {{path/to/copy}}`
- Copy a folder recursively, in verbose mode (shows files as they are copied): - Copy a directory recursively, in verbose mode (shows files as they are copied):
`cp -vr {{path/to/folder}} {{path/to/copy}}` `cp -vr {{path/to/directory}} {{path/to/copy}}`
- Copy the contents of a folder into another folder: - Copy the contents of a directory into another directory:
`cp -r {{path/to/source_folder/*}} {{path/to/target_folder}}` `cp -r {{path/to/source_directory/*}} {{path/to/target_directory}}`
- Copy text files to another location, in interactive mode (prompts user before overwriting): - Copy text files to another location, in interactive mode (prompts user before overwriting):
`cp -i {{*.txt}} {{path/to/target_folder}}` `cp -i {{*.txt}} {{path/to/target_directory}}`

View file

@ -3,13 +3,13 @@
> A static analysis tool for C/C++ code. > A static analysis tool for C/C++ code.
> Instead of syntax errors, it focuses on the types of bugs that compilers normally do not detect. > Instead of syntax errors, it focuses on the types of bugs that compilers normally do not detect.
- Recursively check the current folder, showing progress on the screen and logging error messages to a file: - Recursively check the current directory, showing progress on the screen and logging error messages to a file:
`cppcheck . 2> cppcheck.log` `cppcheck . 2> cppcheck.log`
- Recursively check a given folder, and don't print progress messages: - Recursively check a given directory, and don't print progress messages:
`cppcheck --quiet {{path/to/folder}}` `cppcheck --quiet {{path/to/directory}}`
- Check a given file, specifying which tests to perform (by default only errors are shown): - Check a given file, specifying which tests to perform (by default only errors are shown):
@ -23,9 +23,9 @@
`cppcheck --suppress={{test_id1}} --suppress={{test_id2}} {{path/to/file.cpp}}` `cppcheck --suppress={{test_id1}} --suppress={{test_id2}} {{path/to/file.cpp}}`
- Check the current folder, providing paths for include files located outside it (e.g. external libraries): - Check the current directory, providing paths for include files located outside it (e.g. external libraries):
`cppcheck -I {{include/folder_1}} -I {{include/folder_2}} .` `cppcheck -I {{include/directory_1}} -I {{include/directory_2}} .`
- Check a Microsoft Visual Studio project (`*.vcxproj`) or solution (`*.sln`): - Check a Microsoft Visual Studio project (`*.vcxproj`) or solution (`*.sln`):

View file

@ -2,11 +2,11 @@
> Find unused code in C++ projects. > Find unused code in C++ projects.
- Run in a project's folder: - Run in a project's directory:
`cppclean {{path/to/project}}` `cppclean {{path/to/project}}`
- Run on a project where the headers are in the "inc1/" and "inc2/" folders: - Run on a project where the headers are in the "inc1/" and "inc2/" directories:
`cppclean {{path/to/project}} --include-path={{inc1}} --include-path={{inc2}}` `cppclean {{path/to/project}} --include-path={{inc1}} --include-path={{inc2}}`

View file

@ -10,6 +10,6 @@
`df -h` `df -h`
- Display the file system and its disk usage containing the given file or folder: - Display the file system and its disk usage containing the given file or directory:
`df {{path/to/file_or_folder}}` `df {{path/to/file_or_directory}}`

View file

@ -1,27 +1,27 @@
# du # du
> Disk usage: estimate and summarize file and folder space usage. > Disk usage: estimate and summarize file and directory space usage.
- List the sizes of a folder and any subfolders, in the given unit (B/KB/MB): - List the sizes of a directory and any subdirectories, in the given unit (B/KB/MB):
`du -{{b|k|m}} {{path/to/folder}}` `du -{{b|k|m}} {{path/to/directory}}`
- List the sizes of a folder and any subfolders, in human-readable form (i.e. auto-selecting the appropriate unit for each size): - List the sizes of a directory and any subdirectories, in human-readable form (i.e. auto-selecting the appropriate unit for each size):
`du -h {{path/to/folder}}` `du -h {{path/to/directory}}`
- Show the size of a single folder, in human readable units: - Show the size of a single directory, in human readable units:
`du -sh {{path/to/folder}}` `du -sh {{path/to/directory}}`
- List the human-readable sizes of a folder and of all the files and folders within it: - List the human-readable sizes of a directory and of all the files and directories within it:
`du -ah {{path/to/folder}}` `du -ah {{path/to/directory}}`
- List the human-readable sizes of a folder and any subfolders, up to N levels deep: - List the human-readable sizes of a directory and any subdirectories, up to N levels deep:
`du -h --max-depth=N {{path/to/folder}}` `du -h --max-depth=N {{path/to/directory}}`
- List the human-readable size of all .jpg files in subfolders of the current folder, and show a cumulative total at the end: - List the human-readable size of all .jpg files in subdirectories of the current directory, and show a cumulative total at the end:
`du -ch */*.jpg` `du -ch */*.jpg`

View file

@ -7,7 +7,7 @@
`FTP_PASSWORD={{ftp_login_password}} PASSPHRASE={{encryption_password}} duplicity {{path/to/source/directory}} {{ftps://user@hostname/target/directory/path/}}` `FTP_PASSWORD={{ftp_login_password}} PASSPHRASE={{encryption_password}} duplicity {{path/to/source/directory}} {{ftps://user@hostname/target/directory/path/}}`
- Backup a folder to Amazon S3, doing a full backup every month: - Backup a directory to Amazon S3, doing a full backup every month:
`duplicity --full-if-older-than {{1M}} --use-new-style s3://{{bucket_name[/prefix]}}` `duplicity --full-if-older-than {{1M}} --use-new-style s3://{{bucket_name[/prefix]}}`
@ -17,7 +17,7 @@
- List the available backups: - List the available backups:
`duplicity collection-status "file://{{absolute/path/to/backup/folder}}"` `duplicity collection-status "file://{{absolute/path/to/backup/directory}}"`
- List the files in a backup stored on a remote machine, via ssh: - List the files in a backup stored on a remote machine, via ssh:

View file

@ -19,7 +19,7 @@
`git checkout --track {{remote_name}}/{{branch_name}}` `git checkout --track {{remote_name}}/{{branch_name}}`
- Discard all unstaged changes in the current folder (see `git reset` for more undo-like commands): - Discard all unstaged changes in the current directory (see `git reset` for more undo-like commands):
`git checkout .` `git checkout .`
@ -27,6 +27,6 @@
`git checkout {{file_name}}` `git checkout {{file_name}}`
- Replace a file in the current folder with the version of it committed in a given branch: - Replace a file in the current directory with the version of it committed in a given branch:
`git checkout {{branch_name}} -- {{file_name}}` `git checkout {{branch_name}} -- {{file_name}}`

View file

@ -3,18 +3,18 @@
> Manage multiple working trees attached to the same repository. > Manage multiple working trees attached to the same repository.
> Homepage: <https://git-scm.com/docs/git-worktree>. > Homepage: <https://git-scm.com/docs/git-worktree>.
- Create a new folder with the specified branch checked out into it: - Create a new directory with the specified branch checked out into it:
`git worktree add {{path/to/folder}} {{branch}}` `git worktree add {{path/to/directory}} {{branch}}`
- Create a new folder with a new branch checked out into it: - Create a new directory with a new branch checked out into it:
`git worktree add {{path/to/folder}} -b {{new_branch}}` `git worktree add {{path/to/directory}} -b {{new_branch}}`
- List all the working directories attached to this repository: - List all the working directories attached to this repository:
`git worktree list` `git worktree list`
- Remove a worktree (after deleting worktree folder): - Remove a worktree (after deleting worktree directory):
`git worktree prune` `git worktree prune`

View file

@ -7,9 +7,9 @@
`gitk` `gitk`
- Show repository browser for a specific file or folder: - Show repository browser for a specific file or directory:
`gitk {{path/to/file_or_folder}}` `gitk {{path/to/file_or_directory}}`
- Show commits made since 1 week ago: - Show commits made since 1 week ago:

View file

@ -1,7 +1,7 @@
# gource # gource
> Renders an animated tree diagram of Git, SVN, Mercurial and Bazaar repositories. > Renders an animated tree diagram of Git, SVN, Mercurial and Bazaar repositories.
> It shows files and folders being created, modified or removed over time. > It shows files and directories being created, modified or removed over time.
- Run gource in a directory (if it isn't the repository's root directory, the root is seeked up from there): - Run gource in a directory (if it isn't the repository's root directory, the root is seeked up from there):

View file

@ -14,7 +14,7 @@
`gradle build --offline` `gradle build --offline`
- Clear the build folder: - Clear the build directory:
`gradle clean` `gradle clean`

View file

@ -7,9 +7,9 @@
`ipfs add {{filename}}` `ipfs add {{filename}}`
- Add a folder and its files recursively from local to the file system and print the relative hash: - Add a directory and its files recursively from local to the file system and print the relative hash:
`ipfs add -r {{folder}}` `ipfs add -r {{directory}}`
- Save a remote file and give it a name but not pin it: - Save a remote file and give it a name but not pin it:

View file

@ -10,6 +10,6 @@
`jekyll serve --incremental` `jekyll serve --incremental`
- Generate the current folder into "./_site": - Generate the current directory into "./_site":
`jekyll build` `jekyll build`

View file

@ -1,6 +1,6 @@
# ln # ln
> Creates links to files and folders. > Creates links to files and directories.
- Create a symbolic link to a file or directory: - Create a symbolic link to a file or directory:

View file

@ -1,7 +1,7 @@
# mc # mc
> Midnight Commander, a terminal based file manager. > Midnight Commander, a terminal based file manager.
> Navigate the folder structure using the arrow keys, the mouse or by typing the commands into the terminal. > Navigate the directory structure using the arrow keys, the mouse or by typing the commands into the terminal.
- Start mc: - Start mc:

View file

@ -2,7 +2,7 @@
> Creates a directory. > Creates a directory.
- Create a directory in current folder or given path: - Create a directory in current directory or given path:
`mkdir {{directory}}` `mkdir {{directory}}`

View file

@ -8,7 +8,7 @@
- Run tests contained at a specific location: - Run tests contained at a specific location:
`mocha {{folder/with/tests}}` `mocha {{directory/with/tests}}`
- Run tests that match a specific grep pattern: - Run tests that match a specific grep pattern:

View file

@ -3,7 +3,7 @@
> Perform operations on multiple images, such as resizing, cropping, flipping, and adding effects. > Perform operations on multiple images, such as resizing, cropping, flipping, and adding effects.
> Changes are applied directly to the original file. > Changes are applied directly to the original file.
- Resize all JPEG images in the folder to 50% of their initial size: - Resize all JPEG images in the directory to 50% of their initial size:
`mogrify -resize {{50%}} {{*.jpg}}` `mogrify -resize {{50%}} {{*.jpg}}`
@ -11,7 +11,7 @@
`mogrify -resize {{800x600}} {{DSC*}}` `mogrify -resize {{800x600}} {{DSC*}}`
- Convert all PNG images in the folder to JPEG: - Convert all PNG images in the directory to JPEG:
`mogrify -format {{jpg}} {{*.png}}` `mogrify -format {{jpg}} {{*.png}}`

View file

@ -2,13 +2,13 @@
> Utility to export the contents of a MongoDB instance. > Utility to export the contents of a MongoDB instance.
- Create a dump of all databases (this will place the files inside a folder called "dump"): - Create a dump of all databases (this will place the files inside a directory called "dump"):
`mongodump` `mongodump`
- Specify an output location for the dump: - Specify an output location for the dump:
`mongodump --out {{path/to/folder}}` `mongodump --out {{path/to/directory}}`
- Create a dump of a given database: - Create a dump of a given database:

View file

@ -2,13 +2,13 @@
> Utility to import a collection or database from a binary dump into a MongoDB instance. > Utility to import a collection or database from a binary dump into a MongoDB instance.
- Import a bson data dump from a folder to a MongoDB database: - Import a bson data dump from a directory to a MongoDB database:
`mongorestore --db {{database_name}} {{path/to/folder}}` `mongorestore --db {{database_name}} {{path/to/directory}}`
- Import a bson data dump from a folder to a given database in a MongoDB server host, running at a given port, with user authentication (user will be prompted for password): - Import a bson data dump from a directory to a given database in a MongoDB server host, running at a given port, with user authentication (user will be prompted for password):
`mongorestore --host {{database_host:port}} --db {{database_name}} --username {{username}} {{path/to/folder}} --password` `mongorestore --host {{database_host:port}} --db {{database_name}} --username {{username}} {{path/to/directory}} --password`
- Import a collection from a bson file to a MongoDB database: - Import a collection from a bson file to a MongoDB database:

View file

@ -19,7 +19,7 @@
`mvn install` `mvn install`
- Delete build artifacts from the target folder: - Delete build artifacts from the target directory:
`mvn clean` `mvn clean`

View file

@ -2,7 +2,7 @@
> Command Line Interface (CLI) for creating and managing Angular applications. > Command Line Interface (CLI) for creating and managing Angular applications.
- Create a new Angular application inside a folder: - Create a new Angular application inside a directory:
`ng new {{project_name}}` `ng new {{project_name}}`

View file

@ -19,6 +19,6 @@
`pt -G='{{\.bar$}}' {{foo}}` `pt -G='{{\.bar$}}' {{foo}}`
- Find files whose contents match the regular expression, up to 2 folders deep: - Find files whose contents match the regular expression, up to 2 directories deep:
`pt --depth={{2}} -e '{{^ba[rz]*$}}'` `pt --depth={{2}} -e '{{^ba[rz]*$}}'`

View file

@ -14,7 +14,7 @@
`rbenv global {{version}}` `rbenv global {{version}}`
- Use a specific version of Ruby for an application/project folder: - Use a specific version of Ruby for an application/project directory:
`rbenv local {{version}}` `rbenv local {{version}}`

View file

@ -2,33 +2,33 @@
> CLI program to copy/sync/move files and directories to and from many cloud services. > CLI program to copy/sync/move files and directories to and from many cloud services.
- List contents of a folder on an rclone remote: - List contents of a directory on an rclone remote:
`rclone lsf {{remote_name}}:{{path/to/folder}}` `rclone lsf {{remote_name}}:{{path/to/directory}}`
- Copy file or folder from local source to remote destination: - Copy file or directory from local source to remote destination:
`rclone copy {{path/to/source_file_or_folder}} {{remote_name}}:{{path/to/destination_folder}}` `rclone copy {{path/to/source_file_or_directory}} {{remote_name}}:{{path/to/destination_directory}}`
- Copy file or folder from remote source to local destination: - Copy file or directory from remote source to local destination:
`rclone copy {{remote_name}}:{{path/to/source_file_or_folder}} {{path/to/destination_folder}}` `rclone copy {{remote_name}}:{{path/to/source_file_or_directory}} {{path/to/destination_directory}}`
- Sync local source to remote destination, changing the destination only: - Sync local source to remote destination, changing the destination only:
`rclone sync {{path/to/file_or_folder}} {{remote_name}}:{{path/to/folder}}` `rclone sync {{path/to/file_or_directory}} {{remote_name}}:{{path/to/directory}}`
- Move file or folder from local source to remote destination: - Move file or directory from local source to remote destination:
`rclone move {{path/to/file_or_folder}} {{remote_name}}:{{path/to/folder}}` `rclone move {{path/to/file_or_directory}} {{remote_name}}:{{path/to/directory}}`
- Delete remote file or folder (use `--dry-run` to test, remove it to actually delete): - Delete remote file or directory (use `--dry-run` to test, remove it to actually delete):
`rclone --dry-run delete {{remote_name}}:{{path/to/file_or_folder}}` `rclone --dry-run delete {{remote_name}}:{{path/to/file_or_directory}}`
- Mount rclone remote (experimental): - Mount rclone remote (experimental):
`rclone mount {{remote_name}}:{{path/to/folder}} {{path/to/mount_point}}` `rclone mount {{remote_name}}:{{path/to/directory}} {{path/to/mount_point}}`
- Unmount rclone remote if CTRL-C fails (experimental): - Unmount rclone remote if CTRL-C fails (experimental):

View file

@ -3,15 +3,15 @@
> Multi-pattern string replacement and file renaming tool. > Multi-pattern string replacement and file renaming tool.
> Homepage: <https://github.com/jlevy/repren>. > Homepage: <https://github.com/jlevy/repren>.
- Do a dry-run renaming a folder of pngs with a literal string replacement: - Do a dry-run renaming a directory of pngs with a literal string replacement:
`repren --dry-run --rename --literal --from '{{find_string}}' --to '{{replacement_string}}' {{*.png}}` `repren --dry-run --rename --literal --from '{{find_string}}' --to '{{replacement_string}}' {{*.png}}`
- Do a dry-run renaming a folder of jpegs with a regular expression: - Do a dry-run renaming a directory of jpegs with a regular expression:
`repren --rename --dry-run --from '{{regular_expression}}' --to '{{replacement_string}}' {{*.jpg}} {{*.jpeg}}` `repren --rename --dry-run --from '{{regular_expression}}' --to '{{replacement_string}}' {{*.jpg}} {{*.jpeg}}`
- Do a find-and-replace on the contents of a folder of csv files: - Do a find-and-replace on the contents of a directory of csv files:
`repren --from '{{([0-9]+) example_string}}' --to '{{replacement_string \1}}' {{*.csv}}` `repren --from '{{([0-9]+) example_string}}' --to '{{replacement_string \1}}' {{*.csv}}`

View file

@ -6,9 +6,9 @@
`restic init -r {{path/to/repository}}` `restic init -r {{path/to/repository}}`
- Backup folder "my_folder" to the repository: - Backup a directory to the repository:
`restic -r {{path/to/repository}} backup {{path/to/my_folder}}` `restic -r {{path/to/repository}} backup {{path/to/directory}}`
- Show backup snapshots currently stored in the repository: - Show backup snapshots currently stored in the repository:

View file

@ -7,9 +7,9 @@
`scp {{path/to/local_file}} {{remote_host}}:{{path/to/remote_file}}` `scp {{path/to/local_file}} {{remote_host}}:{{path/to/remote_file}}`
- Copy a file from a remote host to a local folder: - Copy a file from a remote host to a local directory:
`scp {{remote_host}}:{{path/to/remote_file}} {{path/to/local_dir}}` `scp {{remote_host}}:{{path/to/remote_file}} {{path/to/local_directory}}`
- Recursively copy the contents of a directory from a remote host to a local directory: - Recursively copy the contents of a directory from a remote host to a local directory:
@ -17,11 +17,11 @@
- Copy a file between two remote hosts transferring through the local host: - Copy a file between two remote hosts transferring through the local host:
`scp -3 {{host1}}:{{path/to/remote_file}} {{host2}}:{{path/to/remote_dir}}` `scp -3 {{host1}}:{{path/to/remote_file}} {{host2}}:{{path/to/remote_directory}}`
- Use a specific username when connecting to the remote host: - Use a specific username when connecting to the remote host:
`scp {{path/to/local_file}} {{remote_username}}@{{remote_host}}:{{path/to/remote_dir}}` `scp {{path/to/local_file}} {{remote_username}}@{{remote_host}}:{{path/to/remote_directory}}`
- Use a specific ssh private key for authentication with the remote host: - Use a specific ssh private key for authentication with the remote host:

View file

@ -2,7 +2,7 @@
> Send email from the command line. > Send email from the command line.
- Send a message with the content of message.txt to the mail folder of local user `user_name`: - Send a message with the content of message.txt to the mail directory of local user `user_name`:
`sendmail {{user_name}} < {{message.txt}}` `sendmail {{user_name}} < {{message.txt}}`

View file

@ -20,9 +20,9 @@
`put {{/path/local_file}}` `put {{/path/local_file}}`
- Transfer remote folder to the local system recursively (works with `put` too): - Transfer remote directory to the local system recursively (works with `put` too):
`get -R {{/path/remote_folder}}` `get -R {{/path/remote_directory}}`
- Get list of files on local machine: - Get list of files on local machine:

View file

@ -20,4 +20,4 @@
- List version of dependency: - List version of dependency:
`shards version {{path/to/dependency_folder}}` `shards version {{path/to/dependency_directory}}`

View file

@ -10,7 +10,7 @@
`spike watch` `spike watch`
- Compile your project once to the "public" folder: - Compile your project once to the "public" directory:
`spike compile` `spike compile`

View file

@ -5,20 +5,20 @@
- Symlink all files recursively to a given directory: - Symlink all files recursively to a given directory:
`stow --target={{path/to/target_directory}} {{file1 folder1 file2 folder2}}` `stow --target={{path/to/target_directory}} {{file1 directory1 file2 directory2}}`
- Delete symlinks recursively from a given directory: - Delete symlinks recursively from a given directory:
`stow --delete --target={{path/to/target_directory}} {{file1 folder1 file2 folder2}}` `stow --delete --target={{path/to/target_directory}} {{file1 directory1 file2 directory2}}`
- Simulate to see what the result would be like: - Simulate to see what the result would be like:
`stow --simulate --target={{path/to/target_directory}} {{file1 folder1 file2 folder2}}` `stow --simulate --target={{path/to/target_directory}} {{file1 directory1 file2 directory2}}`
- Delete and resymlink: - Delete and resymlink:
`stow --restow --target={{path/to/target_directory}} {{file1 folder1 file2 folder2}}` `stow --restow --target={{path/to/target_directory}} {{file1 directory1 file2 directory2}}`
- Exclude files matching a regular expression: - Exclude files matching a regular expression:
`stow --ignore={{regex}} --target={{path/to/target_directory}} {{file1 folder1 file2 folder2}}` `stow --ignore={{regex}} --target={{path/to/target_directory}} {{file1 directory1 file2 directory2}}`

View file

@ -11,13 +11,13 @@
`svgo {{test.svg}} {{test.min.svg}}` `svgo {{test.svg}} {{test.min.svg}}`
- Optimize all SVG files within a folder (overwrites the original files): - Optimize all SVG files within a directory (overwrites the original files):
`svgo -f {{path/to/folder/with/svg/files}}` `svgo -f {{path/to/directory/with/svg/files}}`
- Optimize all SVG files within a folder and save the resulting files to another folder: - Optimize all SVG files within a directory and save the resulting files to another directory:
`svgo -f {{path/to/input/folder}} -o {{path/to/output/folder}}` `svgo -f {{path/to/input/directory}} -o {{path/to/output/directory}}`
- Optimize SVG content passed from another command, and save the result to a file: - Optimize SVG content passed from another command, and save the result to a file:

View file

@ -11,9 +11,9 @@
`tar -czf {{target.tar.gz}} {{file1 file2 file3}}` `tar -czf {{target.tar.gz}} {{file1 file2 file3}}`
- Extract an archive in a target folder: - Extract an archive in a target directory:
`tar -xf {{source.tar}} -C {{folder}}` `tar -xf {{source.tar}} -C {{directory}}`
- Extract a gzipped archive in the current directory: - Extract a gzipped archive in the current directory:

View file

@ -14,6 +14,6 @@
`echo "example" | tee {{/dev/tty}} | {{xargs printf "[%s]"}}` `echo "example" | tee {{/dev/tty}} | {{xargs printf "[%s]"}}`
- Create a folder called "example", count the number of characters in "example" and write "example" to the terminal: - Create a directory called "example", count the number of characters in "example" and write "example" to the terminal:
`echo "example" | tee >(xargs mkdir) >(wc -c)` `echo "example" | tee >(xargs mkdir) >(wc -c)`

View file

@ -2,18 +2,18 @@
> A program that prints out statistics about code. > A program that prints out statistics about code.
- Get a report on the code in a folder and all subfolders: - Get a report on the code in a directory and all subdirectories:
`tokei {{path/to/folder}}` `tokei {{path/to/directory}}`
- Get a report for a folder excluding `.min.js` files: - Get a report for a directory excluding `.min.js` files:
`tokei {{path/to/folder}} -e {{*.min.js}}` `tokei {{path/to/directory}} -e {{*.min.js}}`
- Print out statistics for individual files in a folder: - Print out statistics for individual files in a directory:
`tokei {{path/to/folder}} --files` `tokei {{path/to/directory}} --files`
- Get a report for all files of type Rust and Markdown: - Get a report for all files of type Rust and Markdown:
`tokei {{path/to/folder}} -t={{Rust}},{{Markdown}}` `tokei {{path/to/directory}} -t={{Rust}},{{Markdown}}`

View file

@ -2,7 +2,7 @@
> Manage lightweight, reproducible, and portable development environments. > Manage lightweight, reproducible, and portable development environments.
- Create Vagrantfile in current folder with the base Vagrant box: - Create Vagrantfile in current directory with the base Vagrant box:
`vagrant init` `vagrant init`

View file

@ -9,7 +9,7 @@
- Create a new project with a local template: - Create a new project with a local template:
`vue init {{path/to/template_folder}} {{project_name}}` `vue init {{path/to/template_directory}} {{project_name}}`
- Create project using template on GitHub: - Create project using template on GitHub:

View file

@ -1,6 +1,6 @@
# chattr # chattr
> Change attributes of files or folders. > Change attributes of files or directories.
- Make a file or directory immutable to changes and deletion, even by superuser: - Make a file or directory immutable to changes and deletion, even by superuser:
@ -10,6 +10,6 @@
`chattr -i {{path/to/file_or_directory}}` `chattr -i {{path/to/file_or_directory}}`
- Recursively make an entire folder and contents immutable: - Recursively make an entire directory and contents immutable:
`chattr -R +i {{folder}}` `chattr -R +i {{path/to/directory}}`

View file

@ -2,7 +2,7 @@
> Run arbitrary commands when files change. > Run arbitrary commands when files change.
- Rebuild with `make` if any files in any subfolders change: - Rebuild with `make` if any file in any subdirectory changes:
`{{ag -l}} | entr {{make}}` `{{ag -l}} | entr {{make}}`

View file

@ -4,12 +4,12 @@
- Display the file access control list: - Display the file access control list:
`getfacl {{path/to/file_or_folder}}` `getfacl {{path/to/file_or_directory}}`
- Display the file access control list with numeric user and group IDs: - Display the file access control list with numeric user and group IDs:
`getfacl -n {{path/to/file_or_folder}}` `getfacl -n {{path/to/file_or_directory}}`
- Display the file access control list with tabular output format: - Display the file access control list with tabular output format:
`getfacl -t {{path/to/file_or_folder}}` `getfacl -t {{path/to/file_or_directory}}`

View file

@ -1,12 +1,12 @@
# mkisofs # mkisofs
> Create ISO files from folders. > Create ISO files from directories.
> Also aliased as `genisoimage`. > Also aliased as `genisoimage`.
- Create an ISO from a folder: - Create an ISO from a directory:
`mkisofs -o {{filename.iso}} {{path/to/source_folder}}` `mkisofs -o {{filename.iso}} {{path/to/source_directory}}`
- Set the disc label when creating an ISO: - Set the disc label when creating an ISO:
`mkisofs -o {{filename.iso}} -V {{"label_name"}} {{path/to/source_folder}}` `mkisofs -o {{filename.iso}} -V {{"label_name"}} {{path/to/source_directory}}`

View file

@ -16,8 +16,8 @@
- Download a file from the server: - Download a file from the server:
`smbclient {{//server/share}} --directory {{path/to/folder}} --command "get {{file.txt}}"` `smbclient {{//server/share}} --directory {{path/to/directory}} --command "get {{file.txt}}"`
- Upload a file to the server: - Upload a file to the server:
`smbclient {{//server/share}} --directory {{path/to/folder}} --command "put {{file.txt}}"` `smbclient {{//server/share}} --directory {{path/to/directory}} --command "put {{file.txt}}"`

View file

@ -1,26 +1,26 @@
# tomb # tomb
> Manage encrypted storage folders that can be safely transported and hidden in a filesystem. > Manage encrypted storage directories that can be safely transported and hidden in a filesystem.
- Create a new tomb with an initial size of 100MB: - Create a new tomb with an initial size of 100MB:
`tomb dig -s {{100}} {{encrypted_folder.tomb}}` `tomb dig -s {{100}} {{encrypted_directory.tomb}}`
- Create a new key file that can be used to lock a tomb; user will be prompted for a password for the key: - Create a new key file that can be used to lock a tomb; user will be prompted for a password for the key:
`tomb forge {{encrypted_folder.tomb.key}}` `tomb forge {{encrypted_directory.tomb.key}}`
- Initialize and lock an empty tomb using a key made with `forge`: - Initialize and lock an empty tomb using a key made with `forge`:
`tomb lock {{encrypted_folder.tomb}} -k {{encrypted_folder.tomb.key}}` `tomb lock {{encrypted_directory.tomb}} -k {{encrypted_directory.tomb.key}}`
- Mount a tomb (by default in /media) using its key, making it usable as a regular filesystem folder: - Mount a tomb (by default in /media) using its key, making it usable as a regular filesystem directory:
`tomb open {{encrypted_folder.tomb}} -k {{encrypted_folder.tomb.key}}` `tomb open {{encrypted_directory.tomb}} -k {{encrypted_directory.tomb.key}}`
- Close a tomb (fails if the tomb is being used by a process): - Close a tomb (fails if the tomb is being used by a process):
`tomb close {{encrypted_folder.tomb}}` `tomb close {{encrypted_directory.tomb}}`
- Forcefully close all open tombs, killing any applications using them: - Forcefully close all open tombs, killing any applications using them:

View file

@ -2,7 +2,7 @@
> Execute a command repeatedly, and monitor the output in full-screen mode. > Execute a command repeatedly, and monitor the output in full-screen mode.
- Monitor files in the current folder: - Monitor files in the current directory:
`watch {{ls}}` `watch {{ls}}`

View file

@ -1,8 +1,8 @@
# ditto # ditto
> Copy files and folders. > Copy files and directories.
- Overwrite contents of destination folder with contents of source folder: - Overwrite contents of destination directory with contents of source directory:
`ditto {{path/to/source}} {{path/to/destination}}` `ditto {{path/to/source}} {{path/to/destination}}`
@ -10,6 +10,6 @@
`ditto -V {{path/to/source}} {{path/to/destination}}` `ditto -V {{path/to/source}} {{path/to/destination}}`
- Copy a given file or folder, while retaining the original file permissions: - Copy a given file or directory, while retaining the original file permissions:
`ditto -rsrc {{path/to/source}} {{path/to/destination}}` `ditto -rsrc {{path/to/source}} {{path/to/destination}}`

View file

@ -6,6 +6,6 @@
`drutil eject` `drutil eject`
- Burn a folder as an ISO9660 filesystem onto a DVD. Don't verify and eject when complete: - Burn a directory as an ISO9660 filesystem onto a DVD. Don't verify and eject when complete:
`drutil burn -noverify -eject -iso9660` `drutil burn -noverify -eject -iso9660`

View file

@ -1,27 +1,27 @@
# du # du
> Disk usage: estimate and summarize file and folder space usage. > Disk usage: estimate and summarize file and directory space usage.
- List the sizes of a folder and any subfolders, in the given unit (KB/MB/GB): - List the sizes of a directory and any subdirectories, in the given unit (KB/MB/GB):
`du -{{k|m|g}} {{path/to/folder}}` `du -{{k|m|g}} {{path/to/directory}}`
- List the sizes of a folder and any subfolders, in human-readable form (i.e. auto-selecting the appropriate unit for each size): - List the sizes of a directory and any subdirectories, in human-readable form (i.e. auto-selecting the appropriate unit for each size):
`du -h {{path/to/folder}}` `du -h {{path/to/directory}}`
- Show the size of a single folder, in human readable units: - Show the size of a single directory, in human readable units:
`du -sh {{path/to/folder}}` `du -sh {{path/to/directory}}`
- List the human-readable sizes of a folder and of all the files and folders within it: - List the human-readable sizes of a directory and of all the files and directories within it:
`du -ah {{path/to/folder}}` `du -ah {{path/to/directory}}`
- List the human-readable sizes of a folder and any subfolders, up to N levels deep: - List the human-readable sizes of a directory and any subdirectories, up to N levels deep:
`du -h -d {{N}} {{path/to/folder}}` `du -h -d {{N}} {{path/to/directory}}`
- List the human-readable size of all .jpg files in subfolders of the current folder, and show a cumulative total at the end: - List the human-readable size of all .jpg files in subdirectories of the current directory, and show a cumulative total at the end:
`du -ch */*.jpg` `du -ch */*.jpg`

View file

@ -15,7 +15,7 @@
`sips -Z {{1920}} {{300}} {{image.ext}}` `sips -Z {{1920}} {{300}} {{image.ext}}`
- Resample all images in a folder to fit a width of 960px (honoring aspect ratio): - Resample all images in a directory to fit a width of 960px (honoring aspect ratio):
`sips --resampleWidth {{960}} {{path/to/images}}` `sips --resampleWidth {{960}} {{path/to/images}}`

View file

@ -18,7 +18,7 @@
`tree -i -f` `tree -i -f`
- Print the size of each node next to it, in human-readable format, with folders displaying their cumulative size (as in the `du` command): - Print the size of each node next to it, in human-readable format, with directories displaying their cumulative size (as in the `du` command):
`tree -s -h --du` `tree -s -h --du`

View file

@ -10,7 +10,7 @@
`attrib /S` `attrib /S`
- Display the attributes of the files and folders in the current directory and sub-directories: - Display the attributes of the files and directories in the current directory and sub-directories:
`attrib /S /D` `attrib /S /D`
@ -22,6 +22,6 @@
`attrib -S -H {{document.txt}}` `attrib -S -H {{document.txt}}`
- Add the hidden attribute to a folder: - Add the hidden attribute to a directory:
`attrib +H {{path\to\folder}}` `attrib +H {{path\to\directory}}`

View file

@ -4,31 +4,31 @@
- Copy the file(s) to the specified destination: - Copy the file(s) to the specified destination:
`xcopy {{path/to/file_or_folder}} {{path/to/destination}}` `xcopy {{path/to/file_or_directory}} {{path/to/destination}}`
- List files that will be copied before copying: - List files that will be copied before copying:
`xcopy {{path/to/file_or_folder}} {{path/to/destination}} /p` `xcopy {{path/to/file_or_directory}} {{path/to/destination}} /p`
- Copy the directory structure only, excluding files: - Copy the directory structure only, excluding files:
`xcopy {{path/to/file_or_folder}} {{path/to/destination}} /t` `xcopy {{path/to/file_or_directory}} {{path/to/destination}} /t`
- Include empty directories when copying: - Include empty directories when copying:
`xcopy {{path/to/file_or_folder}} {{path/to/destination}} /e` `xcopy {{path/to/file_or_directory}} {{path/to/destination}} /e`
- Keep the source ACL in the destination: - Keep the source ACL in the destination:
`xcopy {{path/to/file_or_folder}} {{path/to/destination}} /o` `xcopy {{path/to/file_or_directory}} {{path/to/destination}} /o`
- Allow resuming when network connection is lost: - Allow resuming when network connection is lost:
`xcopy {{path/to/file_or_folder}} {{path/to/destination}} /z` `xcopy {{path/to/file_or_directory}} {{path/to/destination}} /z`
- Disable the prompt when the file exists in the destination: - Disable the prompt when the file exists in the destination:
`xcopy {{path/to/file_or_folder}} {{path/to/destination}} /y` `xcopy {{path/to/file_or_directory}} {{path/to/destination}} /y`
- Display detailed usage information: - Display detailed usage information: