Skip to content

Commit

Permalink
April 2020 (#75)
Browse files Browse the repository at this point in the history
  • Loading branch information
denisidoro authored Apr 20, 2020
1 parent 13e68df commit 8b86719
Show file tree
Hide file tree
Showing 160 changed files with 1,510 additions and 1,463 deletions.
7 changes: 2 additions & 5 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,10 @@
path = modules/dotlink
url = [email protected]:denisidoro/dotlink.git
shallow = true
ignore = dirty

[submodule "modules/zimfw"]
path = modules/zimfw
url = [email protected]:zimfw/zimfw.git
shallow = true

[submodule "modules/z.lua"]
path = modules/z.lua
url = [email protected]:skywind3000/z.lua.git
shallow = true
ignore = dirty
15 changes: 8 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<span><img width="18" src="https://image.flaticon.com/icons/svg/226/226772.svg" alt="Linux - Icon made by Freepik from Flaticon" /></span>
<span><img width="18" src="https://image.flaticon.com/icons/svg/174/174836.svg" alt="Android - Icon made by Freepik from Flaticon" /></span>
denisidoro/dotfiles
<a alt="CI status" href="https://github.com/denisidoro/navi/actions"><img src="https://github.com/denisidoro/dotfiles/workflows/Tests/badge.svg" /></a>
<a alt="CI status" href="https://github.com/denisidoro/dotfiles/actions"><img src="https://github.com/denisidoro/dotfiles/workflows/Tests/badge.svg" /></a>
<a alt="GitHub release" href="https://github.com/denisidoro/dotfiles/releases"><img src="https://img.shields.io/github/v/release/denisidoro/dotfiles?include_prereleases" /></a>
</h3>

Expand All @@ -25,11 +25,11 @@
brew install denisidoro/tools/dotfiles

# with git
git clone https://github.com/denisidoro/dotfiles $HOME/.dotfiles
$HOME/.dotfiles/bin/dot self install
git clone https://github.com/denisidoro/dotfiles $HOME/dotfiles
$HOME/dotfiles/bin/dot self install
```

## ⌨️ Usage
## ⌨️ Calling scripts
```bash
dot <cmd> <args>... # dot rice pipes, for example
```
Expand All @@ -43,7 +43,7 @@ dot <cmd> <args>... # dot rice pipes, for example
## 🎯 Overriding configs

Edit the following files accordingly:
```sh
```bash
# shell
~/.dotfiles/local/zshrc

Expand All @@ -52,5 +52,6 @@ Edit the following files accordingly:
```

## 🌟 Inspiration
* https://github.com/Tuurlijk/dotfiles: Zsh startup snappiness
* https://github.com/rgomezcasas/dotfiles: fine-tuning
* [Tuurlijk/dotfiles](https://github.com/Tuurlijk/dotfiles): zsh startup snappiness
* [rgomezcasas/dotfiles](https://github.com/rgomezcasas/dotfiles): README, some scripts and fine-tuning
* [wfxr/forgit](https://github.com/wfxr/forgit): some git scripts
6 changes: 4 additions & 2 deletions bin/dot
Original file line number Diff line number Diff line change
Expand Up @@ -118,12 +118,14 @@ _alias() {
net) echo network ;;
pkg) echo package ;;
sec) echo security ;;
aws) echo cloud ;;
sh) echo shell ;;
fs) echo filesystem ;;
not) echo notification ;;
google) echo search ;;
down) echo torrent ;;
download) echo torrent ;;
down) echo download ;;
downloads) echo download ;;
torrent) echo download ;;
*) echo "$arg" ;;
esac
}
Expand Down
6 changes: 1 addition & 5 deletions bin/dotn
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,4 @@ export DOTFILES="${DOTFILES:-$(cd "$(dirname "${BASH_SOURCE[0]}")/.." >/dev/null
##? Usage:
##? dot <context> <cmd> [<args>...]

ctx="$1"
cmd="$2"
shift 2

NAVI_PATH="${DOTFILES}/cheats" navi best "${ctx} ${cmd}" "${@:-}"
NAVI_PATH="${DOTFILES}/cheats" navi best "${@:-}"
13 changes: 13 additions & 0 deletions bin/git-dot
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#!/usr/bin/env bash
# vim: filetype=sh
set -euo pipefail

export dot_bin_dir="$(cd "$(dirname "${BASH_SOURCE[0]}")" >/dev/null && pwd)"

##? A hub for an all-purpose set of scripts, using navi
#?? 0.1.0
##?
##? Usage:
##? dot <context> <cmd> [<args>...]

"${dot_bin_dir}/dot" git "$@"
2 changes: 1 addition & 1 deletion cheats/android.cheat
Original file line number Diff line number Diff line change
Expand Up @@ -32,4 +32,4 @@ $ ssh_config: echo "${PREFIX}/etc/ssh/sshd_config"
% android, apps

# Open Google Play Store profile page for an app
dot search lucky "<query> site:play.google.com"
dot browser google-lucky "<query> site:play.google.com"
4 changes: 4 additions & 0 deletions cheats/bash.cheat
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
% bash

# cheat.sh for command
curl "cheat.sh/<command>"
20 changes: 10 additions & 10 deletions cheats/brew.cheat
Original file line number Diff line number Diff line change
@@ -1,30 +1,30 @@
% brew, cask

# get info for a package
# Get info for a package
brew info <package>

# get info for a cask
# Get info for a cask
brew cask info <casks>

# install a package
# Install a package
brew install <package>

# install a cask
# Install a cask
brew cask install <casks>

# uninstall a package
# Uninstall a package
brew uninstall <installed>

# uninstall a cask
brew cask uninstall <caskinstalled>
# Uninstall a cask
brew cask uninstall <installed_cask>

# edit package
# Edit package
brew edit <package>

# edit cask
# Edit cask
brew cask edit <casks>

$ package: brew search
$ casks: brew search --casks
$ installed: brew list
$ caskinstalled: brew cask list
$ installed_cask: brew cask list
2 changes: 1 addition & 1 deletion cheats/clojure.cheat
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
% clojure, clj

# Start a Clojure REPL using deps aliases
clj "-A:${alias}"
clj "-A:<alias>"

$ alias: cat "${HOME}/.clojure/deps.edn" | dot clojure data -o json | jq -r '.aliases | keys | .[]'
3 changes: 3 additions & 0 deletions cheats/code.cheat
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,6 @@

# Beautify source code
dot code beautify <path>

# Search for cheatsheets
curl -s "https://cheat.sh/<query>"
6 changes: 6 additions & 0 deletions cheats/docker.cheat
Original file line number Diff line number Diff line change
Expand Up @@ -77,3 +77,9 @@ docker-compose logs -f --tail 100 <service_name>

# Stops containers and removes containers, networks created by up
docker-compose down


% docker, boot

# Prevent all containers from autostarting on boot
docker update --restart=no $(docker ps -a -q)
16 changes: 4 additions & 12 deletions cheats/dot_pkg.cheat
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,8 @@
# List all recipes
dot pkg recipe list

# Install a package
dot pkg add "<package>"
# Install packages
packages=($(echo "<packages>"))
dot pkg add "${packages[@]}"

# Uninstall a package
dot pkg remove "<package>"

# Update a package
dot pkg update "<package>"

# Upgrade a package
dot pkg upgrade "<package>"

$ package: dot pkg recipe list
$ packages: dot pkg recipe list --- --multi
6 changes: 6 additions & 0 deletions cheats/editor.cheat
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
% editor, vscode

# List VSCode commands
echo "<vscode_action>"

$ vscode_action: curl -sL "https://raw.githubusercontent.com/aburok/mysettings/master/VisualStudio/vscommands.txt"
7 changes: 5 additions & 2 deletions cheats/filesystem.cheat
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,8 @@
# Delete all broken symlinks in the current directory
find -L . -name . -o -type d -prune -o -type l -exec rm {} +

# Use fzf to jump navigate folders
dot fs nav
# Use fzf to navigate folders
dot fs nav

# Folder size
du -sh
Loading

0 comments on commit 8b86719

Please sign in to comment.