Skip to content

Commit

Permalink
feat: add dotbot
Browse files Browse the repository at this point in the history
  • Loading branch information
nsetyo committed Dec 28, 2023
1 parent f615110 commit 34a6efe
Show file tree
Hide file tree
Showing 88 changed files with 68 additions and 53 deletions.
7 changes: 7 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
[*]
end_of_line = lf
insert_final_newline = true

[*.yaml]
indent_style = space
indent_size = 2
4 changes: 4 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
[submodule "dotbot"]
path = dotbot
url = https://github.com/anishathalye/dotbot
ignore = dirty
18 changes: 0 additions & 18 deletions .gtkrc-2.0

This file was deleted.

2 changes: 0 additions & 2 deletions .npmrc

This file was deleted.

File renamed without changes.
21 changes: 6 additions & 15 deletions .bashrc → bashrc
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
# .bashrc

# Source global definitions
if [ -f /etc/bashrc ]; then
. /etc/bashrc
fi
if [ -f /etc/bashrc ]; then . /etc/bashrc; fi

# User specific environment
if ! [[ "$PATH" =~ "$HOME/.local/bin:$HOME/bin:" ]]
Expand All @@ -15,21 +13,14 @@ export PATH

# User specific aliases and functions

if [ -f ~/.aliases ]; then
. ~/.aliases
fi
if [ -f "$HOME/.aliases" ]; then . "$HOME/.aliases"; fi

if [ -f ~/.environment ]; then
. ~/.environment
fi
if [ -f "$HOME/.env" ]; then . "$HOME/.env"; fi

if command -v starship &> /dev/null
then
eval "$(starship init bash)"
fi
if [ -f "$HOME/.cargo/env" ]; then . "$HOME/.cargo/env"; fi

if command -v starship &> /dev/null; then eval "$(starship init bash)"; fi


bind '"\e[1;5A":history-search-backward'
bind '"\e[1;5B":history-search-forward'

. "$HOME/.cargo/env"
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
1 change: 1 addition & 0 deletions dotbot
Submodule dotbot added at 3f9e40
2 changes: 1 addition & 1 deletion etc/sysctl.d/40-swappiness.conf
Original file line number Diff line number Diff line change
@@ -1 +1 @@
vm.swappiness = 1
vm.swappiness=1
File renamed without changes.
15 changes: 15 additions & 0 deletions install
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
#!/usr/bin/env bash

set -e

CONFIG="install.conf.yaml"
DOTBOT_DIR="dotbot"

DOTBOT_BIN="bin/dotbot"
BASEDIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"

cd "${BASEDIR}"
git -C "${DOTBOT_DIR}" submodule sync --quiet --recursive
git submodule update --init --recursive "${DOTBOT_DIR}"

"${BASEDIR}/${DOTBOT_DIR}/${DOTBOT_BIN}" -d "${BASEDIR}" -c "${CONFIG}" "${@}"
25 changes: 25 additions & 0 deletions install.conf.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
- defaults:
link:
relink: true

- clean: ["~"]

- link:
~/.aliases: aliases
~/.bashrc: bashrc
~/.inputrc: inputrc
~/.npmrc: npmrc
~/.vimrc: vimrc
~/.zshrc: zshrc
~/.config/starship.toml:
create: true
path: config/starship.toml
~/.env:
if: "[ -f .env ]"
path: .env

- create:
- ~/.vim/undo-history

- shell:
- [git submodule update --init --recursive, Installing submodules]
2 changes: 2 additions & 0 deletions npmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
cache=${HOME}/.cache/npm
prefix=${HOME}/.local/
File renamed without changes.
24 changes: 7 additions & 17 deletions .zshrc → zshrc
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ ZSH_THEME="robbyrussell"
# ENABLE_CORRECTION="true"

# Uncomment the following line to display red dots whilst waiting for completion.
# COMPLETION_WAITING_DOTS="true"
COMPLETION_WAITING_DOTS="true"

# Uncomment the following line if you want to disable marking untracked files
# under VCS as dirty. This makes repository status check for large repositories
Expand Down Expand Up @@ -76,9 +76,11 @@ source $ZSH/oh-my-zsh.sh
# You may need to manually set your language environment
# export LANG=en_US.UTF-8

if [ -f ~/.env ]; then
source ~/.env
fi
if [ -f ~/.aliases ]; then source ~/.aliases; fi

if [ -f ~/.env ]; then source ~/.env; fi

if [ -f $CARGO_HOME/env ]; then source $CARGO_HOME/env; fi

# Compilation flags
# export ARCHFLAGS="-arch x86_64"
Expand All @@ -92,18 +94,6 @@ fi
# alias zshconfig="mate ~/.zshrc"
# alias ohmyzsh="mate ~/.oh-my-zsh"

if command -v starship &> /dev/null; then
eval "$(starship init zsh)"
fi

if [ -f ~/.aliases ]; then
source ~/.aliases
fi

if [ -f $CARGO_HOME/env ]; then
source $CARGO_HOME/env
fi

if [ -e /home/nsetyo/.nix-profile/etc/profile.d/nix.sh ]; then . /home/nsetyo/.nix-profile/etc/profile.d/nix.sh; fi # added by Nix installer
if command -v starship &> /dev/null; then eval "$(starship init zsh)"; fi


0 comments on commit 34a6efe

Please sign in to comment.