Skip to content

ixtenu/script

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

75 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Scripts

Utility scripts for Unix(-like) operating systems.

Index

Portable:

  • fmtw: fmt(1) wrapper to rewrap text at a given line width.
  • fmtp: fmt(1) wrapper to rewrap text at a given line width while preserving a prefix (such as a comment token, e.g., // or #). 80p is an alias for fmtp -w80.
  • fmtbl: fmt(1) wrapper to rewrap bulleted lists at a given line width. 72bl and 80bl are aliases for fmtbl -w72 and fmtbl -w80, respectively.
  • fmts: a "smart" wrapper around fmtw, fmtp, and fmtbl, which examines the input text and picks which script to use. 72 and 80 are aliases for fmts -w72 and fmts -w80, respectively.
  • et: expand(1) wrapper; accepts optional file name arguments.
  • ut: unexpand(1) wrapper; accepts optional file name arguments.
  • c: sed(1) wrapper to comment-out lines.
  • uc: sed(1) wrapper to uncomment-out lines.
  • lower and upper are trivial tr wrappers to convert text to lowercase or uppercase.
  • i: indent text by one tab (default) or four spaces (with -e) or an arbitrary number of spaces (with -E n). is is an alias for i -e.
  • ui: unindent text by one level (by default, four spaces and/or one tab, which works for either, as long as tabs don't follow spaces; also implements -e and -E n options to unindent spaces only).
  • f: search for file names with fd or, if that's not available, with find(1).
  • s: recursively search file contents with rg, ag, or grep(1), in that order of preference.
  • rd2u: recursively run dos2unix(1) on all files in a directory (and its subdirectories) which contain DOS newlines.
  • ci and cs are thin wrapper scripts for the cindex and csearch programs from codesearch. pci and pcs are variant wrapper scripts for using a project-specific index file.
  • mktag and tag are universal-ctag wrapper scripts. mktag generates the tags file: if PWD is within a Git repository, it automatically finds the top-level directory in the repository and runs ctags -R from there. tag is a readtag(1) wrapper which converts the given tag into filename:lineno.
  • mkexe: touch(1) and chmod +x paths in one command.
  • no9: remove $PLAN9/bin (see plan9port) from the $PATH, if present, and run a command.
  • md2htm: use pandoc to convert a Markdown file to HTML and optionally open it in a web browser.
  • ddiso: dd(1) wrapper for writing an ISO to a disk.
  • ddwipe: dd(1) wrapper for wiping a disk.
  • Git subcommand aliases: gita (git add), gitc (git commit), gitca (git commit --amend), gitcp (git cherry-pick), gitd (git diff), gitdc (git diff --cached), gitp (git pull), git1 (git show), gits (git status), gitu (git push).
  • ssh-ak-add: safely append a public key to $HOME/.ssh/authorized_keys.
  • setpipefail: does set -o pipefail if the shell supports it (currently, support is assumed except for the Linux dash shell used by Debian-based distros). Does nothing useful on its own; it's meant to be sourced by other scripts.
  • zfs-health: Health check-up for systems running ZFS.
  • Text editor wrapper scripts which implement partial support for .editorconfig files:
  • vol: Volume (audio) control.
  • mic: Enable or disable the microphone.
  • bl: Backlight brightness control.
  • nix-zsh: nix-shell(1) wrapper script which adds --run zsh to the command-line parameters.

Linux-specific:

install.sh creates symbolic links in $HOME/bin for the scripts in this repository.

About

utility scripts for Unix(-like) systems

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages