@sebastienrousseau/dotfiles 0.2.458 β†’ 0.2.460

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (115) hide show
  1. package/README.md +62 -11
  2. package/dist/Makefile +35 -57
  3. package/dist/bin/backup.js.map +1 -1
  4. package/dist/bin/constants.d.ts +2 -2
  5. package/dist/bin/constants.d.ts.map +1 -1
  6. package/dist/bin/constants.js +1 -1
  7. package/dist/bin/constants.js.map +1 -1
  8. package/dist/bin/dotfiles.js +1 -1
  9. package/dist/bin/dotfiles.js.map +1 -1
  10. package/dist/bin/download.js.map +1 -1
  11. package/dist/bin/transfer.js.map +1 -1
  12. package/dist/bin/unpack.js.map +1 -1
  13. package/dist/filesizes.txt +107 -59
  14. package/dist/lib/aliases/default/default.aliases.sh +2 -8
  15. package/dist/lib/aliases/gcloud/gcloud.aliases.sh +116 -117
  16. package/dist/lib/aliases/git/git.aliases.sh +6 -47
  17. package/dist/lib/aliases/heroku/heroku.aliases.sh +673 -673
  18. package/dist/lib/aliases/jekyll/jekyll.aliases.sh +26 -26
  19. package/dist/lib/aliases/pnpm/pnpm.aliases.sh +36 -36
  20. package/dist/lib/aliases/subversion/subversion.aliases.sh +80 -80
  21. package/dist/lib/aliases/tmux/tmux.aliases.sh +1 -1
  22. package/dist/lib/aliases.sh +1 -1
  23. package/dist/lib/configurations/bash/bashrc +24 -24
  24. package/dist/lib/configurations/curl/curlrc +1 -1
  25. package/dist/lib/configurations/default/color.sh +1 -1
  26. package/dist/lib/configurations/default/constants.sh +41 -0
  27. package/dist/lib/configurations/default/editor.sh +1 -1
  28. package/dist/lib/configurations/default/prompt.sh +1 -1
  29. package/dist/lib/configurations/gem/gemrc +9 -0
  30. package/dist/lib/configurations/{inputrc β†’ input}/inputrc +1 -1
  31. package/dist/lib/configurations/nano/nanorc +34 -0
  32. package/dist/lib/configurations/profile/profile +1 -1
  33. package/dist/lib/configurations/tmux/default +1 -1
  34. package/dist/lib/configurations/tmux/display +1 -1
  35. package/dist/lib/configurations/tmux/linux +1 -1
  36. package/dist/lib/configurations/tmux/navigation +1 -1
  37. package/dist/lib/configurations/tmux/panes +1 -1
  38. package/dist/lib/configurations/tmux/theme +4 -4
  39. package/dist/lib/configurations/tmux/tmux +1 -1
  40. package/dist/lib/configurations/tmux/vi +1 -1
  41. package/dist/lib/configurations/vim/vimrc +1 -1
  42. package/dist/lib/configurations/wget/wgetrc +1 -1
  43. package/dist/lib/configurations/zsh/zshrc +15 -16
  44. package/dist/lib/configurations.sh +1 -1
  45. package/dist/lib/exit.sh +1 -1
  46. package/dist/lib/functions/cdls.sh +1 -1
  47. package/dist/lib/functions/changediskpwd.tmp +17 -0
  48. package/dist/lib/functions/code.tmp +16 -0
  49. package/dist/lib/functions/countdown.tmp +33 -0
  50. package/dist/lib/functions/curlheader.sh +2 -2
  51. package/dist/lib/functions/curltime.sh +3 -4
  52. package/dist/lib/functions/encode64.sh +1 -1
  53. package/dist/lib/functions/environment.sh +2 -3
  54. package/dist/lib/functions/extract.sh +1 -1
  55. package/dist/lib/functions/genpwd.sh +6 -6
  56. package/dist/lib/functions/goto.sh +1 -1
  57. package/dist/lib/functions/headers.tmp +4 -0
  58. package/dist/lib/functions/hidehiddenfiles.sh +1 -1
  59. package/dist/lib/functions/history-all.tmp +7 -0
  60. package/dist/lib/functions/hostinfo.sh +1 -1
  61. package/dist/lib/functions/hstats.sh +2 -2
  62. package/dist/lib/functions/httpdebug.sh +1 -1
  63. package/dist/lib/functions/keygen.sh +1 -1
  64. package/dist/lib/functions/last.sh +1 -1
  65. package/dist/lib/functions/logout.sh +1 -1
  66. package/dist/lib/functions/lowercase.sh +16 -17
  67. package/dist/lib/functions/macos.sh +14 -15
  68. package/dist/lib/functions/matrix.sh +7 -2
  69. package/dist/lib/functions/mcd.sh +1 -1
  70. package/dist/lib/functions/mount_read_only.sh +1 -1
  71. package/dist/lib/functions/myproc.sh +1 -1
  72. package/dist/lib/functions/prependpath.sh +2 -2
  73. package/dist/lib/functions/print.tmp +13 -0
  74. package/dist/lib/functions/ql.sh +1 -1
  75. package/dist/lib/functions/rd.sh +3 -3
  76. package/dist/lib/functions/remove_disk.sh +2 -2
  77. package/dist/lib/functions/ren.sh +1 -1
  78. package/dist/lib/functions/rm.tmp +13 -0
  79. package/dist/lib/functions/rps.tmp +103 -0
  80. package/dist/lib/functions/showhiddenfiles.sh +1 -1
  81. package/dist/lib/functions/size.sh +1 -1
  82. package/dist/lib/functions/stopwatch.sh +1 -1
  83. package/dist/lib/functions/trash.tmp +13 -0
  84. package/dist/lib/functions/tree.tmp +13 -0
  85. package/dist/lib/functions/uppercase.sh +16 -17
  86. package/dist/lib/functions/uuidgen.tmp +27 -0
  87. package/dist/lib/functions/view-source.sh +2 -3
  88. package/dist/lib/functions/vscode.sh +1 -2
  89. package/dist/lib/functions/whoisport.sh +1 -1
  90. package/dist/lib/functions/zipf.sh +2 -2
  91. package/dist/lib/functions.sh +1 -1
  92. package/dist/lib/history.sh +22 -22
  93. package/dist/lib/paths/ant/ant.paths.sh +1 -1
  94. package/dist/lib/paths/default/default.paths.sh +10 -10
  95. package/dist/lib/paths/homebrew/homebrew.paths.sh +1 -1
  96. package/dist/lib/paths/java/java.paths.sh +1 -1
  97. package/dist/lib/paths/maven/maven.paths.sh +1 -1
  98. package/dist/lib/paths/node/node.paths.sh +1 -1
  99. package/dist/lib/paths/nvm/nvm.paths.sh +1 -1
  100. package/dist/lib/paths/pnpm/pnpm.paths.sh +1 -1
  101. package/dist/lib/paths/python/python.paths.sh +3 -3
  102. package/dist/lib/paths/ruby/ruby.paths.sh +1 -1
  103. package/dist/lib/paths/tmux/tmux.paths.sh +1 -1
  104. package/dist/lib/paths.sh +1 -1
  105. package/dist/scripts/backup.sh +89 -0
  106. package/dist/scripts/banner.sh +18 -0
  107. package/dist/scripts/build.sh +39 -0
  108. package/dist/scripts/clean.sh +29 -0
  109. package/dist/scripts/compile.sh +52 -0
  110. package/dist/scripts/copy.sh +106 -0
  111. package/dist/scripts/dotfiles.sh +61 -0
  112. package/dist/scripts/download.sh +33 -0
  113. package/dist/scripts/help.sh +55 -0
  114. package/dist/scripts/unpack.sh +26 -0
  115. package/package.json +14 -37
@@ -1,4 +1,4 @@
1
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
1
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
2
2
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
3
3
  # License: MIT
4
4
 
@@ -1,9 +1,9 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
6
- ## πŸ†…πŸ…°πŸ†πŸ…ΈπŸ…°πŸ…±πŸ…»πŸ…΄πŸ†‚ - Set variables.
6
+ ## πŸ†…πŸ…°πŸ†πŸ…ΈπŸ…°πŸ…±πŸ…»πŸ…΄πŸ†‚ - Set Dotfiles variable.
7
7
  HOSTNAME=$(hostname -f) # hostname of the machine.
8
8
  INPUTRC=${HOME}/.inputrc # set INPUTRC (so that .inputrc is respected)
9
9
  OS_ARCH=$(uname -m) # machine hardware name.
@@ -14,20 +14,20 @@ USER_LANGUAGE="en_GB.UTF-8" # default language.
14
14
  USER=$(whoami) # current user name.
15
15
 
16
16
  ## πŸ…΄πŸ†‡πŸ…ΏπŸ…ΎπŸ†πŸ†ƒπŸ†‚ - Export the variables.
17
- export ARCHFLAGS="-arch ${OS_ARCH}" # archflags for the current machine.
18
- export DOTFILES_VERSION='0.2.458' # version of the dotfiles.
17
+ export ARCHFLAGS="-arch ${OS_ARCH}" # archflags for the current machine.
18
+ export DOTFILES_VERSION='0.2.460' # version of the dotfiles.
19
19
  export DOTFILES="${HOME}"/.dotfiles/lib # path to the cross plaform dotfiles.
20
- export HOSTNAME=${HOSTNAME} # hostname of the machine.
21
- export INPUTRC=${INPUTRC} # set INPUTRC (so that .inputrc is respected)
22
- export LANG=${USER_LANGUAGE} # default language.
23
- export LANGUAGE=${USER_LANGUAGE} # default language.
24
- export LC_ALL=${USER_LANGUAGE} # default language.
25
- export OS_ARCH # machine hardware name.
26
- export OS_NAME # operating system name.
27
- export OS_VERSION # operating system version number.
28
- export SSL_CERT_FILE=${SSL_CERT_FILE} # set the SSL_CERT_FILE environment variable.
29
- export TERM=xterm-256color # default terminal color.
30
- export USER # current user name.
20
+ export HOSTNAME=${HOSTNAME} # hostname of the machine.
21
+ export INPUTRC=${INPUTRC} # set INPUTRC (so that .inputrc is respected)
22
+ export LANG=${USER_LANGUAGE} # default language.
23
+ export LANGUAGE=${USER_LANGUAGE} # default language.
24
+ export LC_ALL=${USER_LANGUAGE} # default language.
25
+ export OS_ARCH # machine hardware name.
26
+ export OS_NAME # operating system name.
27
+ export OS_VERSION # operating system version number.
28
+ export SSL_CERT_FILE=${SSL_CERT_FILE} # set the SSL_CERT_FILE environment variable.
29
+ export TERM=xterm-256color # default terminal color.
30
+ export USER # current user name.
31
31
 
32
32
  ## πŸ…»πŸ…ΎπŸ…°πŸ…³πŸ…΄πŸ†πŸ†‚ - Load the dotfiles.
33
33
  for loaders in "${DOTFILES}"/*.sh; do
@@ -47,4 +47,3 @@ autoload -Uz colors && colors
47
47
 
48
48
  # Starting to find autocorrect rather annoying...
49
49
  unsetopt correct_all
50
-
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
package/dist/lib/exit.sh CHANGED
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
@@ -0,0 +1,17 @@
1
+ #!/usr/bin/env bash
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
+ # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
+ # License: MIT
5
+
6
+ # https://dotfiles.io
7
+ #
8
+ # Description: Mac OS X Dotfiles - Simply designed to fit your shell life.
9
+ #
10
+ # Copyright (c) Sebastien Rousseau 2022. All rights reserved
11
+ # Licensed under the MIT license
12
+ #
13
+
14
+ # changediskpwd: Function to change the password on an encrypted disk image
15
+ # changediskpwd() {
16
+ # hdiutil chpass "$1"
17
+ # }
@@ -0,0 +1,16 @@
1
+ #!/usr/bin/env bash
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
+ # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
+ # License: MIT
5
+
6
+ # https://dotfiles.io
7
+ #
8
+ # Description: Mac OS X Dotfiles - Simply designed to fit your shell life.
9
+ #
10
+ # Copyright (c) Sebastien Rousseau 2022. All rights reserved
11
+ # Licensed under the MIT license
12
+ #
13
+
14
+ # TODO: Fix code function
15
+ # Add Visual Studio Code (code)
16
+ # code () { VSCODE_CWD="$PWD" open -n -b "com.microsoft.VSCode" --args $"*" ;}
@@ -0,0 +1,33 @@
1
+ #!/usr/bin/env bash
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
+ # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
+ # License: MIT
5
+
6
+ # countdown: Function for countdown
7
+
8
+ # TODO: Fix countdown function
9
+ # countdown() {
10
+
11
+ # if [ "$1" == "-h" ] || [ "$1" == "--help" ]; then
12
+ # echo "usage:
13
+ # countdown [SECONDS]
14
+ # countdown"
15
+ # exit 0
16
+ # fi
17
+ # if [ -z "$1" ]; then
18
+ # read -rp "Enter a number of seconds to countdown from: " seconds
19
+ # else
20
+ # seconds=$1
21
+ # fi
22
+ # : "${x=60}"
23
+ # for ((c = 1; c <= seconds; c++)); do
24
+ # sleep 1
25
+ # seconds_remaining=$((seconds - c))
26
+ # echo -ne "\033[2k\rCountdown: $seconds_remaining seconds"
27
+ # done
28
+ # echo -ne "\033[2k\r"
29
+ # echo "Countdown finished on $(date)"
30
+ # }
31
+
32
+ # alias cntd='countdown' # Alias for countdown
33
+ # alias ctd='countdown' # Alias for countdown
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
@@ -16,5 +16,5 @@ curlheader() {
16
16
  fi
17
17
  }
18
18
 
19
- alias clh='curlheader' # Alias for curlheader
19
+ alias clh='curlheader' # Alias for curlheader
20
20
  alias crlhd='curlheader' # Alias for curlheader
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
@@ -15,7 +15,7 @@
15
15
  ## get the timings for a curl to a URL
16
16
  ## usage: curltime $url
17
17
  curltime() {
18
- curl -w "\n\
18
+ curl -w "\n\
19
19
  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”\n\
20
20
  β”‚Time appconnect: %{time_appconnect}s β”‚\n\
21
21
  β”‚Time connect: %{time_connect}s β”‚\n\
@@ -26,6 +26,5 @@ curl -w "\n\
26
26
  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜\n\
27
27
  Time total: %{time_total}s\n\n" -o /dev/null -s "$1"
28
28
  }
29
- alias clh='curlheader' # Alias for curlheader
29
+ alias clh='curlheader' # Alias for curlheader
30
30
  alias crlhd='curlheader' # Alias for curlheader
31
-
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
@@ -1,11 +1,10 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
6
6
  # environment: Function to detect the current environment
7
- environment ()
8
- {
7
+ environment() {
9
8
  # Define a fallback `OS`
10
9
  LOCAL_OS="other"
11
10
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
@@ -1,14 +1,14 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
6
6
  # genpwd: Function to generates a strong random password of 20 characters (similar to Apple)
7
7
  genpwd() {
8
- m=$(openssl rand -base64 32 | cut -c 1-6);
9
- a=$(openssl rand -base64 32 | cut -c 1-6);
10
- c=$(openssl rand -base64 32 | cut -c 1-6);
11
- pwd="$m-$a-$c";
8
+ m=$(openssl rand -base64 32 | cut -c 1-6)
9
+ a=$(openssl rand -base64 32 | cut -c 1-6)
10
+ c=$(openssl rand -base64 32 | cut -c 1-6)
11
+ pwd="$m-$a-$c"
12
12
  echo "[INFO] The password has been copied to the clipboard: $pwd"
13
- echo "$pwd"| pbcopy | pbpaste;
13
+ echo "$pwd" | pbcopy | pbpaste
14
14
  }
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
@@ -0,0 +1,4 @@
1
+ #!/usr/bin/env bash
2
+
3
+ # headers: Function to retrieve the headers of the request.
4
+ #headers() { /usr/bin/curl -X GET -I -L -k -A 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/57.0.2987.133 Safari/537.36' $@ }
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
@@ -0,0 +1,7 @@
1
+ #!/usr/bin/env bash
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
+ # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
+ # License: MIT
5
+
6
+ # history-all: Function to display the full view of the history command
7
+ #function history-all { history -E 1 }
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
@@ -1,9 +1,9 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
6
6
  # hstats: Function to display Ze Shell history stats informaton
7
7
  hstats() {
8
- history | awk '{CMD[$2]++;count++;}END { for (a in CMD)print CMD[a] " " CMD[a]/count*100 "% " a;}' | grep -v "./" | column -c3 -s " " -t | sort -nr | nl | head -n20
8
+ history | awk '{CMD[$2]++;count++;}END { for (a in CMD)print CMD[a] " " CMD[a]/count*100 "% " a;}' | grep -v "./" | column -c3 -s " " -t | sort -nr | nl | head -n20
9
9
  }
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
@@ -1,28 +1,27 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
6
6
  # lowercase: Function to move filenames or directory names to lowercase
7
- lowercase()
8
- {
7
+ lowercase() {
9
8
  if [[ "$#" != 1 ]]; then
10
9
  echo "[ERROR] The filename or directory name is incorrect." >&2
11
10
  return 1
12
11
  fi
13
- for file ; do
14
- filename=${file##*/}
15
- case "${filename}" in
16
- */*) [[ "dirname" = "${file%/*}" ]] ;;
17
- *) dirname=.;;
18
- esac
19
- nf=$(echo "${filename}" | tr '[:upper:]' '[:lower:]')
20
- newname="${dirname}/${nf}"
21
- if [[ "${nf}" != "${filename}" ]]; then
22
- mv "${file}" "${newname}"
23
- echo "[INFO] Renaming ${file} to lowercase: ${newname}"
24
- else
25
- echo "[ERROR] The operation is not valid, ${file} has not changed."
26
- fi
12
+ for file; do
13
+ filename=${file##*/}
14
+ case "${filename}" in
15
+ */*) [[ "dirname" = "${file%/*}" ]] ;;
16
+ *) dirname=. ;;
17
+ esac
18
+ nf=$(echo "${filename}" | tr '[:upper:]' '[:lower:]')
19
+ newname="${dirname}/${nf}"
20
+ if [[ "${nf}" != "${filename}" ]]; then
21
+ mv "${file}" "${newname}"
22
+ echo "[INFO] Renaming ${file} to lowercase: ${newname}"
23
+ else
24
+ echo "[ERROR] The operation is not valid, ${file} has not changed."
25
+ fi
27
26
  done
28
27
  }
@@ -1,28 +1,28 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
6
6
  # πŸ…ΌπŸ…°πŸ…²πŸ…ΎπŸ†‚ πŸ…ΏπŸ…»πŸ†„πŸ…ΆπŸ…ΈπŸ…½πŸ…Ά πŸ…°πŸ…»πŸ…ΈπŸ…°πŸ†‚πŸ…΄πŸ†‚
7
7
 
8
- alias clds='find . -type f -name "*.DS_Store" -ls -delete' # clds: Recursively delete .DS_Store files.
8
+ alias clds='find . -type f -name "*.DS_Store" -ls -delete' # clds: Recursively delete .DS_Store files.
9
9
  alias clls='/System/Library/Frameworks/CoreServices.framework/Frameworks/LaunchServices.framework/Support/lsregister -kill -r -domain local -domain system -domain user && killall Finder' # clls: Clean up LaunchServices to remove duplicates in the 'Open With' menu.
10
- alias emptytrash='rm -rf ~/.Trash/*' # Empty the Trash on all mounted volumes and the main HDD.
11
- alias finderHideHidden='defaults write com.apple.finder ShowAllFiles FALSE' # finderHideHidden: Hide hidden files in Finder.
12
- alias finderShowHidden='defaults write com.apple.finder ShowAllFiles TRUE' # finderShowHidden: Show hidden files in Finder.
13
- alias iphone='open /Applications/Xcode.app/Contents/Developer/Applications/Simulator.app' # iphone: Open the device simulators.
10
+ alias emptytrash='rm -rf ~/.Trash/*' # Empty the Trash on all mounted volumes and the main HDD.
11
+ alias finderHideHidden='defaults write com.apple.finder ShowAllFiles FALSE' # finderHideHidden: Hide hidden files in Finder.
12
+ alias finderShowHidden='defaults write com.apple.finder ShowAllFiles TRUE' # finderShowHidden: Show hidden files in Finder.
13
+ alias iphone='open /Applications/Xcode.app/Contents/Developer/Applications/Simulator.app' # iphone: Open the device simulators.
14
14
  alias noDS='defaults write com.apple.desktopservices DSDontWriteNetworkStores -bool true'
15
- alias ofd='open $PWD' # Open the current directory in a Finder window.
16
- alias purge='rm -rf ~/library/Developer/Xcode/DerivedData/*' # purge: Purging Xcode DerivedData.
15
+ alias ofd='open $PWD' # Open the current directory in a Finder window.
16
+ alias purge='rm -rf ~/library/Developer/Xcode/DerivedData/*' # purge: Purging Xcode DerivedData.
17
17
  alias screensaverDesktop='/System/Library/Frameworks/ScreenSaver.framework/Resources/ScreenSaverEngine.app/Contents/MacOS/ScreenSaverEngine -background' # screensaverDesktop: Run a screensaver on the Desktop.
18
- alias vp='diskutil verifyPermissions /' # vp: Verify macOS Permissions.
19
- alias vv='diskutil verifyvolume /' # vv: Verify macOS Volume.
20
- alias xcode='open -a xcode' # xcode: Launch XCode app in macOS.
18
+ alias vp='diskutil verifyPermissions /' # vp: Verify macOS Permissions.
19
+ alias vv='diskutil verifyvolume /' # vv: Verify macOS Volume.
20
+ alias xcode='open -a xcode' # xcode: Launch XCode app in macOS.
21
21
 
22
22
  # πŸ…ΌπŸ…°πŸ…²πŸ…ΎπŸ†‚ πŸ…ΏπŸ…»πŸ†„πŸ…ΆπŸ…ΈπŸ…½πŸ…Ά πŸ…΅πŸ†„πŸ…½πŸ…²πŸ†ƒπŸ…ΈπŸ…ΎπŸ…½πŸ†‚
23
23
 
24
24
  # Erases purgeable disk space with 0s on the selected disk
25
- freespace(){
25
+ freespace() {
26
26
  if [[ -z "$1" ]]; then
27
27
  echo "Usage: $0 <disk>"
28
28
  echo "Example: $0 /dev/disk1s1"
@@ -38,10 +38,9 @@ freespace(){
38
38
 
39
39
  mp() {
40
40
  # Don't let Preview.app steal focus if the man page doesn't exist
41
- man -w "$@" > /dev/null 2>&1 || man -t "$@" | open -f -a Preview || man "$@"
41
+ man -w "$@" >/dev/null 2>&1 || man -t "$@" | open -f -a Preview || man "$@"
42
42
  }
43
43
 
44
44
  ql() {
45
- (( $# > 0 )) && qlmanage -p "$*" &>/dev/null &
45
+ (($# > 0)) && qlmanage -p "$*" &>/dev/null &
46
46
  }
47
-
@@ -1,9 +1,14 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
6
6
  # matrix: Function to Enable Matrix Effect in the terminal
7
7
  matrix() {
8
- echo -e "\\e[1;40m" ; clear ; while :; do echo $LINES $COLUMNS $(( RANDOM % COLUMNS)) $(( RANDOM % 72 )) ;sleep 0.05; done|awk '{ letters="abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@#$%^&*()"; c=$4; letter=substr(letters,c,1);a[$3]=0;for (x in a) {o=a[x];a[x]=a[x]+1; printf "\033[%s;%sH\033[2;32m%s",o,x,letter; printf "\033[%s;%sH\033[1;37m%s\033[0;0H",a[x],x,letter;if (a[x] >= $1) { a[x]=0; } }}'
8
+ echo "\\e[1;40m"
9
+ clear
10
+ while :; do
11
+ echo $LINES $COLUMNS $((RANDOM % COLUMNS)) $((RANDOM % 72))
12
+ sleep 0.05
13
+ done | awk '{ letters="abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789@#$%^&*()"; c=$4; letter=substr(letters,c,1);a[$3]=0;for (x in a) {o=a[x];a[x]=a[x]+1; printf "\033[%s;%sH\033[2;32m%s",o,x,letter; printf "\033[%s;%sH\033[1;37m%s\033[0;0H",a[x],x,letter;if (a[x] >= $1) { a[x]=0; } }}'
9
14
  }
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
@@ -13,7 +13,7 @@
13
13
 
14
14
  # prependpath: Prepend $PATH without duplicates
15
15
  prependpath() {
16
- if ! echo "${PATH}" | tr ":" "\n" | grep -qx "$1" ; then
16
+ if ! echo "${PATH}" | tr ":" "\n" | grep -qx "$1"; then
17
17
  PATH="$1:${PATH}"
18
18
  fi
19
19
  }
@@ -0,0 +1,13 @@
1
+ #!/usr/bin/env bash
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
+ # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
+ # License: MIT
5
+
6
+ # print: Function to display the argument given
7
+ # print() {
8
+ # if [[ "$#" != 1 ]]; then
9
+ # echo "[ERROR] Please add one argument" >&2
10
+ # return 1
11
+ # fi
12
+ # echo "$1"
13
+ # }
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
@@ -10,6 +10,6 @@ rd() {
10
10
  return 1
11
11
  fi
12
12
  echo "[INFO] The operation completed successfully, directory listing of $1:"
13
- rm -rf "$1" || exit;
14
- ls -lh;
13
+ rm -rf "$1" || exit
14
+ ls -lh
15
15
  }
@@ -1,9 +1,9 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
6
6
  # remove_disk: spin down unneeded disk
7
- remove_disk () {
7
+ remove_disk() {
8
8
  diskutil eject "$1"
9
9
  }
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env bash
2
- # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.458) - https://dotfiles.io
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
3
  # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
4
  # License: MIT
5
5
 
@@ -0,0 +1,13 @@
1
+ #!/usr/bin/env bash
2
+ # πŸ…³πŸ…ΎπŸ†ƒπŸ…΅πŸ…ΈπŸ…»πŸ…΄πŸ†‚ (v0.2.460) - https://dotfiles.io
3
+ # Copyright (c) Sebastien Rousseau 2022. All rights reserved
4
+ # License: MIT
5
+
6
+ # rm: Function to make 'rm' move files to the trash
7
+ # function rm() {
8
+ # if [[ "$#" != 1 ]]; then
9
+ # echo "[ERROR] Please add one argument" >&2
10
+ # return 1
11
+ # fi
12
+ # rm "$1"
13
+ # }