New dotfiles (#3)
* initial * add GH action to build container * update gitmessage * use branch for version * also push sha for funsies * added ssh back in * fix some bugs * try to trim down docker image sizepull/5/head
parent
650f37c07d
commit
258b77a42b
@ -1,5 +0,0 @@
|
||||
Downloads ~/Downloads
|
||||
Go ~/projects/go/src/github.com
|
||||
Home ~/
|
||||
Work ~/projects/work
|
||||
Projects ~/projects
|
@ -0,0 +1,6 @@
|
||||
tools/
|
||||
.git/
|
||||
.gitmodules
|
||||
Dockerfile*
|
||||
LICENSE
|
||||
README.md
|
@ -1,195 +0,0 @@
|
||||
#!/bin/bash
|
||||
#vim: set ft=sh
|
||||
|
||||
# Determine size of a file or total size of a directory
|
||||
function fs() {
|
||||
if du -b /dev/null > /dev/null 2>&1; then
|
||||
local arg=-sbh;
|
||||
else
|
||||
local arg=-sh;
|
||||
fi
|
||||
if [[ -n "$@" ]]; then
|
||||
du $arg -- "$@";
|
||||
else
|
||||
du $arg .[^.]* *;
|
||||
fi;
|
||||
}
|
||||
|
||||
|
||||
# Create a .tar.gz archive, using `zopfli`, `pigz` or `gzip` for compression
|
||||
function targz() {
|
||||
local tmpFile="${@%/}.tar";
|
||||
tar -cvf "${tmpFile}" --exclude=".DS_Store" "${@}" || return 1;
|
||||
|
||||
size=$(
|
||||
stat -f"%z" "${tmpFile}" 2> /dev/null; # OS X `stat`
|
||||
stat -c"%s" "${tmpFile}" 2> /dev/null # GNU `stat`
|
||||
);
|
||||
|
||||
local cmd="";
|
||||
if (( size < 52428800 )) && hash zopfli 2> /dev/null; then
|
||||
# the .tar file is smaller than 50 MB and Zopfli is available; use it
|
||||
cmd="zopfli";
|
||||
else
|
||||
if hash pigz 2> /dev/null; then
|
||||
cmd="pigz";
|
||||
else
|
||||
cmd="gzip";
|
||||
fi;
|
||||
fi;
|
||||
|
||||
echo "Compressing .tar using \`${cmd}\`…";
|
||||
"${cmd}" -v "${tmpFile}" || return 1;
|
||||
[ -f "${tmpFile}" ] && rm "${tmpFile}";
|
||||
echo "${tmpFile}.gz created successfully.";
|
||||
}
|
||||
|
||||
# Create a new directory and enter it
|
||||
function mkd() {
|
||||
mkdir -p "$@" && cd "$_";
|
||||
}
|
||||
|
||||
# runs vim outside of the term by forking the command and gvim, great for my windows box
|
||||
function vd(){
|
||||
if [[ $# -eq 0 ]]; then
|
||||
gvim &
|
||||
else
|
||||
gvim --remote-tab-silent "$@" &
|
||||
fi
|
||||
}
|
||||
|
||||
|
||||
# `v` with no arguments opens the current directory in Vim, otherwise opens the
|
||||
# given location
|
||||
function v(){
|
||||
if [[ $# -eq 0 ]]; then
|
||||
vim .;
|
||||
else
|
||||
vim --remote-tab-silent "$@";
|
||||
fi
|
||||
}
|
||||
|
||||
# `s` with no arguments opens the current directory in Sublime Text, otherwise
|
||||
# opens the given location
|
||||
function s() {
|
||||
if [ $# -eq 0 ]; then
|
||||
subl .;
|
||||
else
|
||||
subl "$@";
|
||||
fi;
|
||||
}
|
||||
|
||||
# delete merged local branches
|
||||
function prunelocal(){
|
||||
for b in `git branch --merged | grep -v \*`; do git branch -D $b; done
|
||||
}
|
||||
|
||||
# generates a public key from a private key
|
||||
function pubkey(){
|
||||
if [[ -z $1 ]]; then
|
||||
echo "Takes a path to a private key and prints a compatible public key to stdout"
|
||||
echo "$1 required: path to a private key"
|
||||
return -1
|
||||
fi
|
||||
|
||||
|
||||
ssh-keygen -y -f $1
|
||||
}
|
||||
# list network interfaces
|
||||
function interfaces(){
|
||||
ifconfig | grep "\: flags" | awk '{print $1}' | sed 's/:$//';
|
||||
}
|
||||
|
||||
# Create a git.io short URL
|
||||
function gitio() {
|
||||
if [ -z "${1}" -o -z "${2}" ]; then
|
||||
echo "Usage: \`gitio slug url\`";
|
||||
return 1;
|
||||
fi;
|
||||
curl -i http://git.io/ -F "url=${2}" -F "code=${1}";
|
||||
}
|
||||
|
||||
# kill the process using the specified port
|
||||
function freeport(){
|
||||
|
||||
if [ -z $1 ]; then
|
||||
echo "usage: freeport <port number>" >&2
|
||||
return 1
|
||||
fi
|
||||
|
||||
lsof -t -i tcp:$1 | xargs kill
|
||||
}
|
||||
|
||||
|
||||
# runs tcp dump on the port specified in $1. $1 defaults to 8080
|
||||
function dumptcp(){
|
||||
local DUMPPORT=$1
|
||||
local DUMPINTERFACE=$2
|
||||
|
||||
if [ -z "$1" ]; then
|
||||
DUMPPORT=8080
|
||||
elif [[ "$1" == "help" ]]; then
|
||||
echo "dumps tcp info at the specified port. Useful for looking at http requests"
|
||||
echo "usage dumptcp <port>"
|
||||
return 1
|
||||
fi
|
||||
|
||||
if [ -z "$2" ]; then
|
||||
DUMPINTERFACE=lo0
|
||||
fi
|
||||
|
||||
echo "dumping tcp connections @ $DUMPINTERFACE on port $DUMPPORT..."
|
||||
|
||||
sudo tcpdump -s 0 -A -i $DUMPINTERFACE "tcp port $DUMPPORT and (((ip[2:2] - ((ip[0]&0xf)<<2)) - ((tcp[12]&0xf0)>>2)) != 0)"
|
||||
}
|
||||
|
||||
# Run `dig` and display the most useful info
|
||||
function digga() {
|
||||
dig +nocmd "$1" any +multiline +noall +answer;
|
||||
}
|
||||
|
||||
# Simple calculator
|
||||
function calc() {
|
||||
local result="";
|
||||
result="$(printf "scale=10;$*\n" | bc --mathlib | tr -d '\\\n')";
|
||||
# └─ default (when `--mathlib` is used) is 20
|
||||
#
|
||||
if [[ "$result" == *.* ]]; then
|
||||
# improve the output for decimal numbers
|
||||
printf "$result" |
|
||||
sed -e 's/^\./0./' # add "0" for cases like ".5"` \
|
||||
-e 's/^-\./-0./' # add "0" for cases like "-.5"`\
|
||||
-e 's/0*$//;s/\.$//'; # remove trailing zeros
|
||||
else
|
||||
printf "$result";
|
||||
fi;
|
||||
printf "\n";
|
||||
}
|
||||
|
||||
# a shortcut for cloning from github
|
||||
# usage: clone user/repo <dir>
|
||||
function clone() {
|
||||
if [ -z "$1" ]; then
|
||||
echo "Missing git repository url ending"
|
||||
echo "usage: clone 'git repository ending' ['target directory name']"
|
||||
else
|
||||
giturl="git@github.com:$1.git"
|
||||
|
||||
if [ -z "$2" ]; then
|
||||
# we DON'T HAVE a target directory
|
||||
git clone $giturl
|
||||
else
|
||||
# we HAVE a target directory
|
||||
git clone $giturl $2
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
# Create a data URL from a file
|
||||
function dataurl() {
|
||||
local mimeType=$(file -b --mime-type "$1");
|
||||
if [[ $mimeType == text/* ]]; then
|
||||
mimeType="${mimeType};charset=utf-8";
|
||||
fi
|
||||
echo "data:${mimeType};base64,$(openssl base64 -in "$1" | tr -d '\n')";
|
||||
}
|
@ -0,0 +1,16 @@
|
||||
name: Docker Image CI
|
||||
|
||||
on: [push]
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- name: Build the Docker image
|
||||
env:
|
||||
DOCKER_USER: ${{ secrets.DOCKER_USERNAME }}
|
||||
DOCKER_PASS: ${{ secrets.DOCKER_PASSWORD }}
|
||||
run: |
|
||||
docker login -u ${DOCKER_USER} -p ${DOCKER_PASS}
|
||||
VERSION=${GITHUB_REF#"refs/heads/"} COMMIT_SHA=${GITHUB_SHA} INITIATOR=${GITHUB_ACTOR} make publish
|
@ -1,12 +1,21 @@
|
||||
[submodule "tools/modules/tmux-MacOSX-pasteboard"]
|
||||
path = tools/modules/tmux-MacOSX-pasteboard
|
||||
url = git://github.com/ChrisJohnsen/tmux-MacOSX-pasteboard.git
|
||||
[submodule "tools/modules/powerline-fonts"]
|
||||
path = tools/modules/powerline-fonts
|
||||
url = git://github.com/Lokaltog/powerline-fonts.git
|
||||
[submodule "tools/modules/iTerm2-Color-Schemes"]
|
||||
path = tools/modules/iTerm2-Color-Schemes
|
||||
[submodule "tmux-MacOSX-pasteboard"]
|
||||
path = tools/osx/iTerm2-Color-Schemes
|
||||
url = git://github.com/mbadolato/iTerm2-Color-Schemes.git
|
||||
[submodule "iTerm2-Color-Schemes"]
|
||||
path = tools/osx/iTerm2-Color-Schemes
|
||||
url = git://github.com/mbadolato/iTerm2-Color-Schemes.git
|
||||
[submodule "tools/modules/powerline"]
|
||||
path = tools/modules/powerline
|
||||
[submodule "powerline-fonts"]
|
||||
path = tools/powerline/powerline-fonts
|
||||
url = git://github.com/Lokaltog/powerline-fonts.git
|
||||
[submodule "powerline"]
|
||||
path = tools/powerline/powerline
|
||||
url = git://github.com/powerline/powerline.git
|
||||
[submodule "polybar-spotify"]
|
||||
path = tools/polybar/polybar-spotify
|
||||
url = git://github.com/Jvanrhijn/polybar-spotify.git
|
||||
[submodule "polypomo"]
|
||||
path = tools/polybar/polypomo
|
||||
url = git://github.com/unode/polypomo.git
|
||||
[submodule "polybar-scripts"]
|
||||
path = tools/polybar/polybar-scripts
|
||||
url = git://github.com/polybar/polybar-scripts.git
|
||||
|
@ -0,0 +1,29 @@
|
||||
FROM debian:bullseye
|
||||
|
||||
ARG version=dev
|
||||
ARG commit=dev
|
||||
ARG created=never
|
||||
|
||||
LABEL maintainer="Adam Veldhousen <adam@veldhousen.net>"
|
||||
LABEL net.veldhousen.version=${version}
|
||||
LABEL net.veldhousen.commit=${commit}
|
||||
LABEL net.veldhousen.created=${created}
|
||||
|
||||
RUN apt-get update && apt-get install -y sudo apt-utils && apt-get clean
|
||||
RUN useradd -G sudo -U -u 1000 -m -s /bin/bash dev \
|
||||
&& echo 'dev:dev' | chpasswd \
|
||||
&& mkdir -p /home/dev/Projects \
|
||||
&& rm -rf /home/dev/.bashrc \
|
||||
&& chown -R dev:dev /home/dev/ \
|
||||
&& echo "dev ALL=(ALL) NOPASSWD: ALL" > /etc/sudoers.d/dev_no_pass
|
||||
|
||||
USER 1000
|
||||
|
||||
WORKDIR /home/dev
|
||||
COPY . /home/dev/Projects/dotfiles
|
||||
RUN /home/dev/Projects/dotfiles/install dev \
|
||||
&& sudo rm -rf /tmp/*
|
||||
|
||||
ENTRYPOINT ["/bin/bash", "--login"]
|
||||
|
||||
|
@ -0,0 +1 @@
|
||||
from archlinux/base
|
@ -0,0 +1,17 @@
|
||||
FROM debian
|
||||
|
||||
COPY . /home/dotfiles/Projects/dotfiles
|
||||
|
||||
RUN apt-get update && apt-get install -y sudo
|
||||
|
||||
RUN useradd -G sudo -U -u 1000 -m -s /bin/bash dotfiles \
|
||||
&& echo 'dotfiles:dotfiles' | chpasswd \
|
||||
&& mkdir -p /home/dotfiles/Projects \
|
||||
&& chown -R dotfiles:dotfiles /home/dotfiles
|
||||
|
||||
|
||||
USER 1000
|
||||
|
||||
WORKDIR /home/dotfiles
|
||||
|
||||
ENTRYPOINT "/bin/bash"
|
@ -0,0 +1,9 @@
|
||||
MIT
|
||||
|
||||
Copyright 2019 Adam Veldhousen
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFWARE.
|
@ -1,42 +1,39 @@
|
||||
laughing-hipster
|
||||
Dotfiles
|
||||
================
|
||||
|
||||
![GitHub](https://img.shields.io/github/license/adamveld12/laughing-hipster)
|
||||
![Platform](https://img.shields.io/badge/platform-Debian%2C%20Ubuntu%2C%20OSX-lightgrey)
|
||||
|
||||
My dot files
|
||||
|
||||
## What's included?
|
||||
|
||||
A very simplistic plugin system, drop shell scripts you would like to source into the ~/.extensions directory. .profile will load them automatically.
|
||||
A very simplistic plugin system, drop shell scripts you would like to source into the `~/.shell_extensions` directory and they get automatically loaded.
|
||||
|
||||
A custom SSH config setup with nice defaults.
|
||||
|
||||
Installs Brew when run on OSX, along with several utilities I commonly use.
|
||||
|
||||
Comes with an uninstall script.
|
||||
|
||||
Themes for vim, iterm2 and for cmder when ran on windows.
|
||||
|
||||
Tmux and vim configurations
|
||||
|
||||
## Install
|
||||
|
||||
1. cd into `~`
|
||||
3. run `laughing-hipster/bootstrap.sh`
|
||||
Tmux and vim configurations.
|
||||
|
||||
The installer backs up your current home folder dotfiles into `.home_bkup` and then symlinks in the dotfiles for this repo. The installer also preserves your ssh config if you have customized it already.
|
||||
i3 (sway if using wayland), compton, polybar, dunst, nitrogen for linux window management.
|
||||
|
||||
Because everything is symlinked, all you have to do for most updates is just `git pull`.
|
||||
## Install
|
||||
|
||||
## Uninstall
|
||||
|
||||
1. cd into `~`
|
||||
2. run `./laughing-hipster/remove.sh`
|
||||
1. Run `./install <username>` and everything is automatically installed:
|
||||
- symlinks `.vimrc`, `.tmux.conf`, `.gitconfig`, `.motd`, `.profile`, `.shell_extensions`, `.config`, `.ssh/config` to home directory
|
||||
- backups existing copies of all files to `.dotfiles_backup_<date>/`
|
||||
- installs rvm, gvm, nvm, rustup
|
||||
- compton, dunst, nitrogen, polybar if x is detected
|
||||
|
||||
|
||||
The uninstaller will leave the ssh config in place and copy all of the files from `.home_bkup` into their original places. It will also remove the tools folder and any dot files that have the same name as the ones in this repo.
|
||||
## Extending with custom scripts
|
||||
|
||||
Basically you end up back where you started (or close to) without anything destructive happening.
|
||||
This set up will source all files found in a `~/.shell_extensions/` directory. This allows you to extend and customize how everything works to your liking.
|
||||
|
||||
## Extending with custom scripts
|
||||
|
||||
This set up will source all files found in a `~/.extensions/` directory or in a file named `~/.extensions` at the last moment. This allows you to extend and customize how everything works to your liking.
|
||||
## LICENSE
|
||||
|
||||
MIT
|
||||
|
@ -1,159 +0,0 @@
|
||||
#!/bin/bash
|
||||
IFS='\n\t'
|
||||
set -euo pipefail
|
||||
|
||||
source="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
||||
dest="$(pwd)"
|
||||
bkup="$dest/.home_bkup"
|
||||
|
||||
|
||||
if [ -d ${bkup} ]; then
|
||||
echo "A backup folder already exists, it must be moved/deleted before bootstrap can apply the new dotfiles."
|
||||
exit -1;
|
||||
fi
|
||||
|
||||
echo ""
|
||||
echo "Making a backup of old dotfiles into ${bkup}..."
|
||||
mkdir -p "${bkup}"
|
||||
|
||||
IFS=$'\n'
|
||||
if [ -f ${dest}/.ssh/config ]; then
|
||||
mkdir -p "${bkup}/.ssh"
|
||||
cp "${dest}/.ssh/config" "${bkup}/.ssh/config"
|
||||
fi
|
||||
for file in $(ls -lA "${source}" | grep "^-" | awk '{print $9}'); do
|
||||
if [ -f "${dest}/${file}" ]; then
|
||||
cp "${dest}/${file}" "${bkup}/${file}"
|
||||
fi
|
||||
done
|
||||
|
||||
echo ""
|
||||
echo "loading git modules in $source..."
|
||||
pushd $source
|
||||
git submodule init
|
||||
git submodule update
|
||||
popd
|
||||
|
||||
echo ""
|
||||
echo "copying \"./tools\" directories..."
|
||||
if [ -z "${dest}/Tools" ]; then
|
||||
mkdir -p ${dest}/tools
|
||||
fi
|
||||
|
||||
#ln -fs ${source}/Tools ${dest}/tools
|
||||
cp -R ${source}/tools ${dest}/tools
|
||||
|
||||
|
||||
echo ""
|
||||
echo "linking dotfiles from ${source} into ${dest}"
|
||||
# ln on windows pretty much only works with hardlinks it seems
|
||||
ls -lA "${source}" | grep "^-" | awk '{print $9}' | xargs -I file ln -fs "${source}/file" "${dest}/file"
|
||||
if [ -z "${dest}/.ssh" ]; then
|
||||
mkdir -p "${dest}/.ssh"
|
||||
fi
|
||||
|
||||
echo ""
|
||||
echo "setting up ssh default"
|
||||
# a check to see if they're using a config file and if it has a host setup
|
||||
if [ -f "${dest}/.ssh/config" && -z $(cat "${dest}/.ssh/config" | grep '[hH]ost \*') ]; then
|
||||
echo "Appending ssh config"
|
||||
# we append it so we don't destroy any custom settings they may have
|
||||
cat "${source}/.ssh/config" >> "${dest}/.ssh/config"
|
||||
elif [ -f "${dest}/.ssh/config" ]; then
|
||||
echo "Your SSHfu is strong, skipping config copy..."
|
||||
else
|
||||
echo "Copying new ssh config"
|
||||
mkdir -p "${dest}/.ssh/"
|
||||
cp -n "${source}/.ssh/config" "${dest}/.ssh/"
|
||||
fi
|
||||
|
||||
|
||||
mkdir -p ${dest}/projects/
|
||||
|
||||
echo ""
|
||||
echo "installing platform stuff"
|
||||
if [ $(uname -s) == "Darwin" ]; then
|
||||
echo "installing fonts"
|
||||
find ${source}/tools/modules/powerline-fonts | grep "\.[to]tf" | xargs -I {} cp {} /Users/$(whoami)/Library/Fonts/
|
||||
|
||||
echo "installing osx stuff"
|
||||
sudo ./install/.osx
|
||||
|
||||
#rake
|
||||
elif [ $(uname -s) == "Linux" ]; then
|
||||
echo "installing linux stuff"
|
||||
${source}/install/debian.sh
|
||||
elif [ $(uname -o) == "Msys" ]; then
|
||||
|
||||
echo "If you would like to install vim plugins, ensure you have ruby 1.9.3 + rake installed and do the following:"
|
||||
echo "rake;"
|
||||
echo "~/tools/vim/bundle/YouCompleteMe/install.py --all;"
|
||||
echo "installing fonts"
|
||||
fonts="$(find ${source}/tools/modules/powerline-fonts | grep "\.[to]tf")"
|
||||
|
||||
mkdir -p "$dest/fonts_to_install"
|
||||
for font in $fonts
|
||||
do
|
||||
fontname="$(basename $font)"
|
||||
cp -n $font "$dest/fonts_to_install/"
|
||||
#reg add "HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Fonts" /v "${fontname} (TrueType)" /t REG_SZ /d "$font" /f
|
||||
done
|
||||
echo "go to $dest/fonts_to_install, select all of the font files and right-click -> install"
|
||||
fi
|
||||
|
||||
if [ -d "${dest}/.extensions" ]; then
|
||||
echo "${dest}/.extensions exists"
|
||||
else
|
||||
mkdir ${dest}/.extensions
|
||||
cat <<EOF >~/.extensions/README.md
|
||||
# Extensions
|
||||
|
||||
All script files in this folder get loaded by the .profile, so this is a nice place to organize plugins
|
||||
or enhancements to the dotfile setup
|
||||
EOF
|
||||
fi
|
||||
|
||||
rbenv install 1.9.3-p125;
|
||||
rbenv global 1.9.3-p125;
|
||||
rbenv rehash
|
||||
|
||||
rm -rf ${dest}/tools/modules/iTerm2-Color-Schemes
|
||||
rm -rf ${dest}/tools/modules/tmux-MacOSX-pasteboard
|
||||
|
||||
#./tools/vim/bundle/YouCompleteMe/install.py --all &
|
||||
|
||||
rake
|
||||
|
||||
|
||||
echo "You must install YouCompleteMe by going to ~/tools/vim/bundle/YouCompleteMe/ and following the instructions in the README.md"
|
||||
|
||||
if [ -f "~/.bashrc" ]; then
|
||||
echo "sourcing .profile in .bashrc"
|
||||
echo "source ./.profile" >> ~/.bashrc
|
||||
fi
|
||||
|
||||
|
||||
echo ""
|
||||
echo "Cleaning up..."
|
||||
cleanup=".git
|
||||
.gitmodules
|
||||
.gitignore
|
||||
install
|
||||
bootstrap.sh
|
||||
remove.sh
|
||||
README.md"
|
||||
|
||||
for f in ${cleanup}
|
||||
do
|
||||
filetorm=${dest}/${f};
|
||||
if [ -f ${filetorm} ]; then
|
||||
rm -rf $filetorm
|
||||
fi
|
||||
done
|
||||
|
||||
|
||||
echo ""
|
||||
echo "To uninstall, do cd ./lauging-hipster && ./remove.sh"
|
||||
echo "Make sure your home_bkup folder is present, so keep it safe in the meantime!"
|
||||
echo "Install ./tools/modules/powerline-fonts and set them up in your terminal to benefit from the custom PS1 in .shell_colors"
|
||||
echo "done!"
|
@ -1,57 +0,0 @@
|
||||
// Place your key bindings in this file to overwrite the defaults
|
||||
[
|
||||
{
|
||||
"key": "ctrl+shift+alt+y",
|
||||
"command": "extension.vim_ctrl+y",
|
||||
"when": "editorTextFocus && vim.active && vim.use<C-y> && !inDebugRepl"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+y",
|
||||
"command": "-extension.vim_ctrl+y",
|
||||
"when": "editorTextFocus && vim.active && vim.use<C-y> && !inDebugRepl"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+y",
|
||||
"command": "redo",
|
||||
"when": "editorTextFocus && !editorReadonly"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+y",
|
||||
"command": "-redo",
|
||||
"when": "editorTextFocus && !editorReadonly"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+w",
|
||||
"command": "-extension.vim_ctrl+w",
|
||||
"when": "editorTextFocus && vim.active && vim.use<C-w> && !inDebugRepl"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+w",
|
||||
"command": "-workbench.action.closeWindow",
|
||||
"when": "!editorIsOpen"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+shift+]",
|
||||
"command": "editor.action.goToDeclaration",
|
||||
"when": "editorHasDefinitionProvider && editorTextFocus && !isInEmbeddedEditor"
|
||||
},
|
||||
{
|
||||
"key": "f12",
|
||||
"command": "-editor.action.goToDeclaration",
|
||||
"when": "editorHasDefinitionProvider && editorTextFocus && !isInEmbeddedEditor"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+n",
|
||||
"command": "workbench.action.files.newUntitledFile"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+\\",
|
||||
"command": "workbench.action.terminal.split",
|
||||
"when": "terminalFocus"
|
||||
},
|
||||
{
|
||||
"key": "ctrl+k ctrl+i",
|
||||
"command": "editor.action.showHover",
|
||||
"when": "editorTextFocus"
|
||||
}
|
||||
]
|
@ -1,72 +0,0 @@
|
||||
{
|
||||
"terminal.integrated.shellArgs.linux": ["--login"],
|
||||
"terminal.integrated.shellArgs.osx": ["--login"],
|
||||
"terminal.integrated.fontFamily": "'Ubuntu Mono derivative Powerline', 'Fira Code Retina:style=Retina', 'PragmataPro', 'Droid Sans Mono', 'monospace', monospace, 'Droid Sans Fallback'",
|
||||
"terminal.integrated.fontSize": 14,
|
||||
"editor.renderWhitespace": "boundary",
|
||||
"editor.formatOnType": true,
|
||||
"editor.formatOnPaste": true,
|
||||
"editor.fontFamily": "'Fira Code Retina', 'Fira Code', 'PragmataPro'",
|
||||
"editor.fontSize": 14,
|
||||
"editor.codeLens": true,
|
||||
"editor.fontLigatures": true,
|
||||
"editor.hideCursorInOverviewRuler": true,
|
||||
"editor.rulers": [120],
|
||||
"eslint.alwaysShowStatus": true,
|
||||
"eslint.autoFixOnSave": true,
|
||||
"eslint.enable": true,
|
||||
"[markdown]": {
|
||||
"editor.wordWrap": "off",
|
||||
"editor.quickSuggestions": {
|
||||
"other": true,
|
||||
"comments": false,
|
||||
"strings": false
|
||||
}
|
||||
},
|
||||
"files.exclude": {
|
||||
"**/.git": true,
|
||||
"**/.svn": true,
|
||||
"**/.hg": true,
|
||||
"**/CVS": true,
|
||||
"**/.DS_Store": true,
|
||||
"**/node_modules": true
|
||||
},
|
||||
"git.enableCommitSigning": true,
|
||||
"git.autofetch": true,
|
||||
"git.autorefresh": true,
|
||||
"go.testOnSave": true,
|
||||
"go.lintOnSave": "package",
|
||||
"go.autocompleteUnimportedPackages": false,
|
||||
"go.formatTool": "goreturns",
|
||||
"prettier.eslintIntegration": true,
|
||||
"prettier.tabWidth": 4,
|
||||
"window.openFilesInNewWindow": "on",
|
||||
"telemetry.enableTelemetry": false,
|
||||
"vim.leader": ",",
|
||||
"vim.surround": true,
|
||||
"vim.useSystemClipboard": true,
|
||||
"workbench.colorTheme": "Cobalt2",
|
||||
"window.zoomLevel": 0,
|
||||
"workbench.activityBar.visible": true,
|
||||
"workbench.editor.enablePreview": false,
|
||||
"workbench.editor.enablePreviewFromQuickOpen": false,
|
||||
"explorer.confirmDragAndDrop": false,
|
||||
"explorer.confirmDelete": false,
|
||||
"[javascript]": {
|
||||
"editor.formatOnSave": true
|
||||
},
|
||||
"fs.inotify.max_user_watches":524288,
|
||||
"gitlens.keymap": "alternate",
|
||||
"gitlens.advanced.messages": {
|
||||
"suppressCommitHasNoPreviousCommitWarning": false,
|
||||
"suppressCommitNotFoundWarning": false,
|
||||
"suppressFileNotUnderSourceControlWarning": false,
|
||||
"suppressGitVersionWarning": false,
|
||||
"suppressLineUncommittedWarning": true,
|
||||
"suppressNoRepositoryWarning": false,
|
||||
"suppressResultsExplorerNotice": false,
|
||||
"suppressShowKeyBindingsNotice": true
|
||||
},
|
||||
"gitlens.historyExplorer.enabled": true,
|
||||
"gitlens.mode.active": "review",
|
||||
}
|
@ -1,8 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
killall -q polybar
|
||||
while pgrep -x polybar >/dev/null; do sleep 1; done
|
||||
|
||||
MONITOR=eDP-1-1 polybar bar1 &
|
||||
MONITOR=DVI-I-3-2 polybar bar1 &
|
||||
MONITOR=DVI-I-2-1 polybar bar1 &
|
@ -1,14 +0,0 @@
|
||||
[xin_0]
|
||||
file=/home/adam/Pictures/Wallpapers/wallhaven-553335.jpg
|
||||
mode=2
|
||||
bgcolor=#6a8397
|
||||
|
||||
[xin_1]
|
||||
file=/home/adam/Pictures/Wallpapers/wallhaven-553335.jpg
|
||||
mode=2
|
||||
bgcolor=#6a8397
|
||||
|
||||
[xin_2]
|
||||
file=/home/adam/Pictures/Wallpapers/wallhaven-553335.jpg
|
||||
mode=2
|
||||
bgcolor=#6a8397
|
@ -0,0 +1,20 @@
|
||||
#!/bin/bash
|
||||
|
||||
BASE_DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd );
|
||||
OLD_DIR=${PWD};
|
||||
cd ${BASE_DIR};
|
||||
./installers/base.sh $@;
|
||||
cd ${OLD_DIR};
|
||||
|
||||
echo "Installation completed."
|
||||
echo "Look in '/home/$@/tools/fonts' to install fonts. There is Fira Code, Pragmata Pro, Iosveka to choose from."
|
||||
|
||||
|
||||
POST_INSTALL_MSG="\t- Keybase: https://keybase.io/docs/the_app/install_linux\n
|
||||
\t- Firefox Developer Edition: https://www.mozilla.org/en-US/firefox/developer/\n
|
||||
\t -Signal: https://signal.org/download/#linuxModal\n
|
||||
\t- Docker: https://docs.docker.com/install/linux/docker-ce/ubuntu/\n
|
||||
\t- or Podman: https://docs.docker.com/install/linux/docker-ce/ubuntu/\n
|
||||
"
|
||||
echo "Some things to install yourself:"
|
||||
echo -e $POST_INSTALL_MSG
|
@ -1,92 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
if [ ! -d ${dest}/config ]; then
|
||||
mkdir -p ${dest}/.config/
|
||||
cp -R ${source}/config/ ${dest}/.config/
|
||||
fi
|
||||
|
||||
apt-get update && apt-get install -y \
|
||||
build-essential \
|
||||
bison \
|
||||
checkinstall \
|
||||
cargo \
|
||||
cmake \
|
||||
cmake-data \
|
||||
compton \
|
||||
curl \
|
||||
git \
|
||||
i3-wm \
|
||||
libunwind-dev \
|
||||
libcairo2-dev \
|
||||
libxcb1-dev \
|
||||
libxcb-ewmh-dev \
|
||||
libxcb-icccm4-dev \
|
||||
libxcb-image0-dev \
|
||||
libxcb-randr0-dev \
|
||||
libxcb-util0-dev \
|
||||
libxcb-xkb-dev \
|
||||
libxcb-xrm-dev \
|
||||
libasound2-dev \
|
||||
libssl-dev \
|
||||
libpulse-dev \
|
||||
libmpdclient-dev \
|
||||
libiw-dev \
|
||||
libcurl4-openssl-dev \
|
||||
libxcb-cursor-dev \
|
||||
nitrogen \
|
||||
pkg-config \
|
||||
python-xcbgen \
|
||||
python \
|
||||
snap \
|
||||
rbenv \
|
||||
ruby-build \
|
||||
rust \
|
||||
terminator \
|
||||
tmux \
|
||||
wget \
|
||||
xcb-proto;
|
||||
|
||||
snap install slack;
|
||||
|
||||
curl https://raw.githubusercontent.com/creationix/nvm/v0.25.0/install.sh | bash
|
||||
bash < <(curl -s -S -L https://raw.githubusercontent.com/moovweb/gvm/master/binscripts/gvm-installer)
|
||||
source ~/.gvm/scripts/gvm
|
||||
gvm install go1.4 -B
|
||||
gvm use go1.4
|
||||
export GOROOT_BOOTSTRAP=$GOROOT
|
||||
gvm install go1.5
|
||||
|
||||
cd ${dest}/projects
|
||||
|
||||
# install polybar
|
||||
git clone --branch 3.1.0 --recursive https://github.com/jaagr/polybar polybar
|
||||
cd ./polybar
|
||||
./build.sh
|
||||
cd ..
|
||||
|
||||
|
||||
# install vim with all of the necessary features
|
||||
git clone https://github.com/vim/vim vim
|
||||
cd ./vim
|
||||
|
||||
./configure --with-features=huge \
|
||||
--enable-multibyte \
|
||||
--enable-rubyinterp=yes \
|
||||
--enable-python3interp=yes \
|
||||
--enable-perlinterp=yes \
|
||||
--enable-luainterp=yes \
|
||||
--enable-gui=gtk2 \
|
||||
--enable-cscope \
|
||||
--prefix=/usr/local
|
||||
|
||||
make VIMRUNTUME=~/tools/vim/
|
||||
|
||||
checkinstall
|
||||
cd ..
|
||||
|
||||
git clone https://github.com/51v4n/i3-gnome i3-gnome
|
||||
cd ./i3-gnome
|
||||
make install
|
||||
cd ..
|
||||
|
||||
cd ${dest}
|
@ -1 +0,0 @@
|
||||
#!/bin/bash
|
@ -0,0 +1,144 @@
|
||||
#!/bin/bash
|
||||
set -eou pipefail
|
||||
shopt -s extglob
|
||||
|
||||
GO_VERSION=1.13
|
||||
NODE_VERSION=12
|
||||
|
||||
linkDirectory() {
|
||||
SOURCE=$1;
|
||||
DEST=$2;
|
||||
echo "LINK $SOURCE -> $DEST"
|
||||
find ${SOURCE} -type d ! -name '.ssh' | sed "s=${SOURCE}==" | xargs -I {} mkdir -p ${DEST}{};
|
||||
find ${SOURCE} -type f ! -path "${SOURCE}/.ssh/config" | sed "s=${SOURCE}==" | xargs -I {} ln -vfs ${SOURCE}{} ${DEST}{};
|
||||
# ln on windows pretty much only works with hardlinks it seems
|
||||
#ls -lA "${SOURCE}" | grep "^-" | awk '{print $9}' | xargs -I {} ln -vfs "${SOURCE}/{}" "${DEST}/{}"
|
||||
}
|
||||
|
||||
if [ -z "$1" ]; then
|
||||
echo "must define home directory";
|
||||
fi
|
||||
|
||||
|
||||
export HOME_DIR=/home/$1;
|
||||
export USER_ARG=$1;
|
||||
BASE_DIR=$( cd "$( dirname "${BASH_SOURCE[0]}" )/.." && pwd );
|
||||
SRC_DIR=${BASE_DIR}/src;
|
||||
TOOLS_DIR=${BASE_DIR}/tools;
|
||||
CONFIG_DIR=${SRC_DIR}/.config;
|
||||
EXT_DIR=${SRC_DIR}/.shell_extensions;
|
||||
export VIMRUNTIME=${HOME}/.config/vim/runtime;
|
||||
|
||||
if [ -d ${HOME_DIR} ]; then
|
||||
echo "installing into ${HOME_DIR}";
|
||||
else
|
||||
echo "${HOME_DIR} doesn't exist";
|
||||
exit 1;
|
||||
fi
|
||||
|
||||
export HOME=${HOME_DIR};
|
||||
|
||||
echo "installing dot files from ${BASE_DIR} into ${HOME_DIR}...";
|
||||
|
||||
mkdir -p ${HOME_DIR}/Projects;
|
||||
mkdir -p ${HOME_DIR}/Downloads;
|
||||
mkdir -p ${HOME_DIR}/Desktop;
|
||||
mkdir -p ${HOME_DIR}/Documents/Pictures/Wallpapers;
|
||||
mkdir -p ${HOME_DIR}/.ssh;
|
||||
|
||||
echo "linking dotfiles from ${SRC_DIR} to ${HOME_DIR}";
|
||||
linkDirectory "${SRC_DIR}" "${HOME_DIR}";
|
||||
|
||||
echo "setting up ssh configuration";
|
||||
# a check to see if they're using a config file and if it has a host setup
|
||||
if [[ -f "${HOME_DIR}/.ssh/config" ]] && [[ -z $(cat "${HOME_DIR}/.ssh/config" | grep '[hH]ost \*') ]]; then
|
||||
echo "Appending ssh config";
|
||||
# we append it so we don't destroy any custom settings they may have
|
||||
cat "${BASE_DIR}/.ssh/config" >> "${HOME_DIR}/.ssh/config";
|
||||
elif [ -f "${HOME_DIR}/.ssh/config" ]; then
|
||||
echo "Your SSHfu is strong, skipping config copy...";
|
||||
else
|
||||
echo "Copying new ssh config";
|
||||
mkdir -p "${HOME_DIR}/.ssh/";
|
||||
cp -n "${SRC_DIR}/.ssh/config" "${HOME_DIR}/.ssh/";
|
||||
fi
|
||||
|
||||
if [ "$(uname)" = "Linux" ]; then
|
||||
source "${BASE_DIR}/installers/linux.sh";
|
||||
rm -rf ${HOME_DIR}/.shell_extensions/osx/;
|
||||
elif [ "$(uname)" = "Darwin" ]; then
|
||||
echo "OSX not supported";
|
||||
source "${BASE_DIR}/installers/osx.sh";
|
||||
rm -rf ${HOME_DIR}/.shell_extensions/linux/;
|
||||
else
|
||||
echo "windows is not supported";
|
||||
fi
|
||||
|
||||
|
||||
#------------------------------------------------------------------
|
||||
# Set up sub modules - link tools into home
|
||||
#------------------------------------------------------------------
|
||||
|
||||
if [ -f "${BASE_DIR}/tools" ]; then
|
||||
git submodule init && git submodule --progress update;
|
||||
linkDirectory ${TOOLS_DIR} ${HOME_DIR}/tools;
|
||||
else
|
||||
echo "skipping tools..."
|
||||
fi
|
||||
|
||||
|
||||
#------------------------------------------------------------------
|
||||
# Set up home directory deps
|
||||
#------------------------------------------------------------------
|
||||
mkdir -p ${HOME_DIR}/.bin;
|
||||
|
||||
echo "setting up vim runtime folder @ ${VIMRUNTIME}";
|
||||
mkdir -p ${VIMRUNTIME}/autoload ${VIMRUNTIME}/bundle && \
|
||||
curl -LSso ${VIMRUNTIME}/autoload/pathogen.vim https://tpo.pe/pathogen.vim;
|
||||
|
||||
|
||||
if [ ! -d "${HOME_DIR}/.gvm/" ]; then
|
||||
# install GVM
|
||||
echo "installing gvm";
|
||||
bash < <(curl -s -S -L https://raw.githubusercontent.com/moovweb/gvm/master/binscripts/gvm-installer);
|
||||
echo "[[ -s \"\$HOME/.gvm/scripts/gvm\" ]] && source \"\$HOME/.gvm/scripts/gvm\"" > ${HOME_DIR}/.shell_extensions/gvm.sh;
|
||||
source ${HOME_DIR}/.gvm/scripts/gvm;
|
||||
gvm install go${GO_VERSION} -B;
|
||||
gvm use go${GO_VERSION} --default;
|
||||
fi
|
||||
|
||||
if [ ! -d "${HOME}/.nvm" ]; then
|
||||
# install nvm
|
||||
echo "installing nvm";
|
||||
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.35.0/install.sh | bash;
|
||||
echo "export NVM_DIR=\"\$HOME/.nvm\"" > "${HOME}/.shell_extensions/nvm.sh";
|
||||
echo '[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"' >> "${HOME}/.shell_extensions/nvm.sh";
|
||||
echo '[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion' >> "${HOME}/.shell_extensions/nvm.sh";
|
||||
NVM_DIR=${HOME}/.nvm;
|
||||
source $NVM_DIR/nvm.sh;
|
||||
|
||||
nvm install v${NODE_VERSION};
|
||||
fi
|
||||
|
||||
if [ ! -d "${HOME}/.cargo" ]; then
|
||||
# install rust
|
||||
echo "installing rustup + rust stable";
|
||||
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs > /tmp/rustup.sh;
|
||||
chmod +x /tmp/rustup.sh && /tmp/rustup.sh -y --no-modify-path;
|
||||
echo 'source $HOME/.cargo/env' > "${HOME}/.shell_extensions/rust.sh";
|
||||
source ${HOME}/.cargo/env
|
||||
rustup install stable;
|
||||
fi
|
||||
|
||||
if [ ! -d "${HOME}/.rvm" ]; then
|
||||
gpg --keyserver hkp://pool.sks-keyservers.net --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 7D2BAF1CF37B13E2069D6956105BD0E739499BDB
|
||||
curl -sSL https://get.rvm.io | bash -s stable --ruby;
|
||||
echo "source \${HOME}/.rvm/scripts/rvm" > "${HOME}/.shell_extensions/rvm.sh"
|
||||
source ${HOME}/.rvm/scripts/rvm
|
||||
fi
|
||||
|
||||
pushd ${HOME}/.config/vim/
|
||||
rake
|
||||
popd
|
||||
|
||||
find ${HOME} ! -path "${HOME}/Projects" ! -path "${HOME}" | xargs -I {} chown $@ {};
|
@ -0,0 +1,98 @@
|
||||
#!/bin/bash
|
||||
|
||||
ALACRITTY_VERSION=0.3.3;
|
||||
|
||||
INSTALL_LIST='ctags dhex neofetch irssi man bison python2 iptables software-properties-common libncurses-dev uidmap gpg apt-transport-https tar zip unzip curl wget git ca-certificates build-essential make cmake gcc tmux apt-utils dnsutils python3 less libassuan-dev libc6-dev libdevmapper-dev libglib2.0-dev libgpgme-dev libgpg-error-dev libostree-dev libprotobuf-dev libprotobuf-c-dev libseccomp-dev libselinux1-dev libsystemd-dev pkg-config runc python-dev python3-dev ruby-dev lua5.1 libperl-dev';
|
||||
|
||||
X_INSTALL_LIST="snapd cairo libxcb terminator compton nitrogen i3 dunst xcb-proto xcb-util-image xcb-util-wm xcb-util-cursor xcb-util-xrm xcb-xk jsoncpp libcurl wireless_tools libmpdclient libx11-dev libxtst-dev" ;
|
||||
|
||||
echo "installing: ${INSTALL_LIST}";
|
||||
|
||||
SUDO="TRUE";
|
||||
|
||||
if [ "${UID}" = 0 ]; then
|
||||
SUDO=""
|
||||
elif [ -z "$(which sudo)" ]; then
|
||||
echo "you must have sudo permissions or be root for this step";
|
||||
exit 1;
|
||||
fi
|
||||
|
||||
sudo apt-get update;
|
||||
sudo apt-get install -y ${INSTALL_LIST};
|
||||
wget -q https://packages.microsoft.com/config/ubuntu/19.04/packages-microsoft-prod.deb -O /tmp/packages-microsoft-prod.deb;
|
||||
sudo dpkg -i /tmp/packages-microsoft-prod.deb;
|
||||
sudo apt-get update;
|
||||
sudo apt-get install -y dotnet-sdk-3.0;
|
||||
|
||||
cd $HOME/Projects
|
||||
|
||||
if [ -z "$(which X)" ]; then
|
||||
echo "no X server setup detected."
|
||||
else
|
||||
sudo apt-get install -y ${X_INSTALL_LIST};
|
||||
curl -L https://github.com/jwilm/alacritty/releases/download/v${ALACRITTY_VERSION}/Alacritty-v${ALACRITTY_VERSION}-ubuntu_18_04_amd64.deb > /tmp/alacritty.deb;
|
||||
sudo apt install -y /tmp/alacritty.deb;
|
||||
|
||||
# install polybar
|
||||
git clone --branch 3.4.0 --recursive https://github.com/polybar/polybar polybar
|
||||
cd ./polybar/build
|
||||
cmake ..
|
||||
make -j$(nproc)
|
||||
sudo make install
|
||||
cd ../..
|
||||
rm -rf ./polybar
|
||||
|
||||
snap install code docker firefox thunderbird insomnia discord slack spotify;
|
||||
fi
|
||||
|
||||
# install vim with all of the necessary features
|
||||
[ ! -s "${HOME}/Projects/vim" ] && git clone --branch v8.1.2109 https://github.com/vim/vim vim
|
||||
cd ./vim
|
||||
|
||||
VIM_CONFIG_ARGS='
|
||||
--enable-multibyte \
|
||||
--enable-rubyinterp=yes \
|
||||
--with-python3-config-dir=/usr/lib/python3.7/config-3.7m-x86_64-linux-gnu \
|
||||
--enable-python3interp=yes \
|
||||
--enable-perlinterp=yes \
|
||||
--enable-luainterp=yes \
|
||||
--disable-netbeans \
|
||||
--with-compiledby="Adam V <adam@veldhousen.net>" \
|
||||
--enable-gui=auto \
|
||||
--enable-cscope \
|
||||
--prefix=/usr/local
|
||||
'
|
||||
|
||||
VIM_CONFIG_X_ARGS='
|
||||
--enable-gtk2-check \
|
||||
--enable-gnome-check \
|
||||
--with-x
|
||||
'
|
||||
if [ ! -z "$(which X)" ]; then
|
||||
echo "adding X options"
|
||||
VIM_CONFIG_ARGS="${VOM_CONFIG_ARGS} ${VIM_CONFIG_X_ARGS}"
|
||||
fi
|
||||
|
||||
./configure ${VIM_CONFIG_ARGS}
|
||||
|
||||
make VIMRUNTUMEDIR=${HOME}/.config/vim/runtime/
|
||||
sudo make install VIMRUNTIMEDIR=${HOME}/.config/vim/runtime/
|
||||
|
||||
|
||||
VIMFILES=/usr/local/share/vim/vim81
|
||||
find ${VIMFILES} -type f | \
|
||||
sed "s=${VIMFILES}==" | \
|
||||
xargs -I {} dirname {} | \
|
||||
xargs -I {} mkdir -p ${VIMRUNTIME}{};
|
||||
|
||||
find ${VIMFILES} -type f | \
|
||||
sed "s=${VIMFILES}==" | \
|
||||
xargs -I {} cp $VIMFILES/{} $VIMRUNTIME{};
|
||||
|
||||
ln -svf ${HOME}/.config/vim/.vimrc ~/.vimrc
|
||||
|
||||
cd ..
|
||||
rm -rf ./vim
|
||||
|
||||
|
||||
cd ${HOME}
|
@ -0,0 +1,35 @@
|
||||
.PHONY: build build-test deb-test dev
|
||||
|
||||
./tools:
|
||||
git submodule init && git submodule update
|
||||
|
||||
build: ./tools
|
||||
docker build -t vdhsn/dotfiles:$${VERSION:-latest} \
|
||||
--build-arg version=$${VERSION} \
|
||||
--build-arg commit=$${COMMIT_SHA:-$${CIRCLE_SHA1}} \
|
||||
--build-arg initiator=$${INITIATOR:-$${CIRCLE_USERNAME}} \
|
||||
--build-arg created=$${CREATED_TS:-$$(date +%s)} \
|
||||
-f ./Dockerfile .
|
||||
|
||||
publish: build
|
||||
docker push vdhsn/dotfiles:$${VERSION}
|
||||
docker tag vdhsn/dotfiles:$${VERSION} vdhsn/dotfiles:$$(echo $${COMMIT_SHA} | sed -E 's/^(.{10}).*$$/\1/')
|
||||
docker push vdhsn/dotfiles:$$(echo $${COMMIT_SHA} | sed -E 's/^(.{10}).*$$/\1/')
|
||||
|
||||
build-test: ./tools
|
||||
docker build -t vdhsn/dotfiles:deb-test -f ./Dockerfile.debian .
|
||||
|
||||
deb-test:
|
||||
docker run -it --rm --name dotfiles \
|
||||
-u $${USER_ID:-1000} \
|
||||
-v $$PWD:/home/dotfiles/Projects/dotfiles:ro \
|
||||
--workdir /home/dotfiles/Projects/dotfiles \
|
||||
vdhsn/dotfiles:deb-test
|
||||
|
||||
dev:
|
||||
docker run -it --rm --name dotfiles \
|
||||
-u $${USER_ID:-1000} \
|
||||
-v $$PWD:/home/dev/Projects/dotfiles:ro \
|
||||
--workdir /home/dev/Projects/dotfiles \
|
||||
vdhsn/dotfiles:$${VERSION:-latest}
|
||||
|
@ -1,28 +0,0 @@
|
||||
#!/bin/bash
|
||||
src=$(pwd)
|
||||
pushd .. 2&> /dev/null
|
||||
dest=$(pwd)
|
||||
|
||||
if [[ -d "$dest/.home_bkup" ]]; then
|
||||
echo "Uninstalling files from ${dest}..."
|
||||
ls -lAp $src | grep "^-" | awk '{print $9}' | xargs -n 1 -I file rm -f $dest/file
|
||||
echo ""
|
||||
|
||||
echo "Restoring from .home_bkup..."
|
||||
ls -lA ./.home_bkup | grep "^-" | awk '{print $9}' | xargs -n 1 -P 8 -I file cp ./.home_bkup/file ./file
|
||||
echo ""
|
||||
|
||||
echo "Cleaning up home backup and tools..."
|
||||
rm -rf ./.home_bkup
|
||||
rm -rf ./tools
|
||||
|
||||
popd 2&> /dev/null
|
||||
echo ""
|
||||
|
||||
echo ".ssh config has been left alone"
|
||||
echo ""
|
||||
|
||||
echo "Restore completed!"
|
||||
else
|
||||
echo "you don't have a home backup, aborting"
|
||||
fi
|
@ -0,0 +1,6 @@
|
||||
# ~/.bash_logout: executed by bash(1) when login shell exits.
|
||||
|
||||
# when leaving the console clear the screen to increase privacy
|
||||
if [ "$SHLVL" = 1 ]; then
|
||||
[ -x /usr/bin/clear_console ] && /usr/bin/clear_console -q
|
||||
fi
|
@ -0,0 +1,269 @@
|
||||
# Configuration for Alacritty, the GPU enhanced terminal emulator
|
||||
|
||||
# Any items in the `env` entry below will be added as
|
||||
# environment variables. Some entries may override variables
|
||||
# set by alacritty it self.
|
||||
env:
|
||||
# TERM env customization.
|
||||
#
|
||||
# If this property is not set, alacritty will set it to xterm-256color.
|
||||
#
|
||||
# Note that some xterm terminfo databases don't declare support for italics.
|
||||
# You can verify this by checking for the presence of `smso` and `sitm` in
|
||||
# `infocmp xterm-256color`.
|
||||
TERM: xterm-256color
|
||||
|
||||
# Window dimensions in character columns and lines
|
||||
# (changes require restart)
|
||||
dimensions:
|
||||
columns: 80
|
||||
lines: 24
|
||||
|
||||
# Adds this many blank pixels of padding around the window
|
||||
# Units are physical pixels; this is not DPI aware.
|
||||
# (change requires restart)
|
||||
padding:
|
||||
x: 2
|
||||
y: 2
|
||||
|
||||
# The FreeType rasterizer needs to know the device DPI for best results
|
||||
# (changes require restart)
|
||||
dpi:
|
||||
x: 96.0
|
||||
y: 96.0
|
||||
|
||||
# Display tabs using this many cells (changes require restart)
|
||||
tabspaces: 4
|
||||
|
||||
# When true, bold text is drawn using the bright variant of colors.
|
||||
draw_bold_text_with_bright_colors: true
|
||||
|
||||
# Font configuration (changes require restart)
|
||||
font:
|
||||
# The normal (roman) font face to use.
|
||||
normal:
|
||||
family: monospace # should be "Menlo" or something on macOS.
|
||||
# Style can be specified to pick a specific face.
|
||||
# style: Regular
|
||||
|
||||
# The bold font face
|
||||
bold:
|
||||
family: monospace # should be "Menlo" or something on macOS.
|
||||
# Style can be specified to pick a specific face.
|
||||
# style: Bold
|
||||
|
||||
# The italic font face
|
||||
italic:
|
||||
family: monospace # should be "Menlo" or something on macOS.
|
||||
# Style can be specified to pick a specific face.
|
||||
# style: Italic
|
||||
|
||||
# Point size of the font
|
||||
size: 11.0
|
||||
|
||||
# Offset is the extra space around each character. offset.y can be thought of
|
||||
# as modifying the linespacing, and offset.x as modifying the letter spacing.
|
||||
offset:
|
||||
x: 0.0
|
||||
y: 0.0
|
||||
|
||||
# Glyph offset determines the locations of the glyphs within their cells with
|
||||
# the default being at the bottom. Increase the x offset to move the glyph to
|
||||
# the right, increase the y offset to move the glyph upward.
|
||||
glyph_offset:
|
||||
x: 0.0
|
||||
y: 0.0
|
||||
|
||||
# OS X only: use thin stroke font rendering. Thin strokes are suitable
|
||||
# for retina displays, but for non-retina you probably want this set to
|
||||
# false.
|
||||
use_thin_strokes: true
|
||||
|
||||
# Should display the render timer
|
||||
render_timer: true
|
||||
|
||||
# Use custom cursor colors. If true, display the cursor in the cursor.foreground
|
||||
# and cursor.background colors, otherwise invert the colors of the cursor.
|
||||
custom_cursor_colors: false
|
||||
|
||||
# Colors (Tomorrow Night Bright)
|
||||
colors:
|
||||
# Default colors
|
||||
primary:
|
||||
background: '0x000000'
|
||||
foreground: '0xeaeaea'
|
||||
|
||||
# Colors the cursor will use if `custom_cursor_colors` is true
|
||||
cursor:
|
||||
text: '0x000000'
|
||||
cursor: '0xffffff'
|
||||
|
||||
# Normal colors
|
||||
normal:
|
||||
black: '0x000000'
|
||||
red: '0xd54e53'
|
||||
green: '0xb9ca4a'
|
||||
yellow: '0xe6c547'
|
||||
blue: '0x7aa6da'
|
||||
magenta: '0xc397d8'
|
||||
cyan: '0x70c0ba'
|
||||
white: '0x424242'
|
||||
|
||||
# Bright colors
|
||||
bright:
|
||||
black: '0x666666'
|
||||
red: '0xff3334'
|
||||
green: '0x9ec400'
|
||||
yellow: '0xe7c547'
|
||||
blue: '0x7aa6da'
|
||||
magenta: '0xb77ee0'
|
||||
cyan: '0x54ced6'
|
||||
white: '0x2a2a2a'
|
||||
|
||||
# Visual Bell
|
||||
#
|
||||
# Any time the BEL code is received, Alacritty "rings" the visual bell. Once
|
||||
# rung, the terminal background will be set to white and transition back to the
|
||||
# default background color. You can control the rate of this transition by
|
||||
# setting the `duration` property (represented in milliseconds). You can also
|
||||
# configure the transition function by setting the `animation` property.
|
||||
#
|
||||
# Possible values for `animation`
|
||||
# `Ease`
|
||||
# `EaseOut`
|
||||
# `EaseOutSine`
|
||||
# `EaseOutQuad`
|
||||
# `EaseOutCubic`
|
||||
# `EaseOutQuart`
|
||||
# `EaseOutQuint`
|
||||
# `EaseOutExpo`
|
||||
# `EaseOutCirc`
|
||||
# `Linear`
|
||||
#
|
||||
# To completely disable the visual bell, set its duration to 0.
|
||||
#
|
||||
visual_bell:
|
||||
animation: EaseOutExpo
|
||||
duration: 1
|
||||
|
||||
# Key bindings
|
||||
#
|
||||
# Each binding is defined as an object with some properties. Most of the
|
||||
# properties are optional. All of the alphabetical keys should have a letter for
|
||||
# the `key` value such as `V`. Function keys are probably what you would expect
|
||||
# as well (F1, F2, ..). The number keys above the main keyboard are encoded as
|
||||
# `Key1`, `Key2`, etc. Keys on the number pad are encoded `Number1`, `Number2`,
|
||||
# etc. These all match the glutin::VirtualKeyCode variants.
|
||||
#
|
||||
# Possible values for `mods`
|
||||
# `Command`, `Super` refer to the super/command/windows key
|
||||
# `Control` for the control key
|
||||
# `Shift` for the Shift key
|
||||
# `Alt` and `Option` refer to alt/option
|
||||
#
|
||||
# mods may be combined with a `|`. For example, requiring control and shift
|
||||
# looks like:
|
||||
#
|
||||
# mods: Control|Shift
|
||||
#
|
||||
# The parser is currently quite sensitive to whitespace and capitalization -
|
||||
# capitalization must match exactly, and piped items must not have whitespace
|
||||
# around them.
|
||||
#
|
||||
# Either an `action` or `chars` field must be present. `chars` writes the
|
||||
# specified string every time that binding is activated. These should generally
|
||||
# be escape sequences, but they can be configured to send arbitrary strings of
|
||||
# bytes. Possible values of `action` include `Paste` and `PasteSelection`.
|
||||
#
|
||||
# Want to add a binding (e.g. "PageUp") but are unsure what the X sequence
|
||||
# (e.g. "\x1b[5~") is? Open another terminal (like xterm) without tmux,
|
||||
# then run `showkey -a` to get the sequence associated to a key combination.
|
||||
key_bindings:
|
||||
- { key: V, mods: Control|Shift, action: Paste }
|
||||
- { key: C, mods: Control|Shift, action: Copy }
|
||||
- { key: Q, mods: Command, action: Quit }
|
||||
- { key: W, mods: Command, action: Quit }
|
||||
- { key: Insert, mods: Shift, action: PasteSelection }
|
||||
- { key: Home, chars: "\x1bOH", mode: AppCursor }
|
||||
- { key: Home, chars: "\x1b[1~", mode: ~AppCursor }
|
||||
- { key: End, chars: "\x1bOF", mode: AppCursor }
|
||||
- { key: End, chars: "\x1b[4~", mode: ~AppCursor }
|
||||
- { key: PageUp, mods: Shift, chars: "\x1b[5;2~" }
|
||||
- { key: PageUp, mods: Control, chars: "\x1b[5;5~" }
|
||||
- { key: PageUp, chars: "\x1b[5~" }
|
||||
- { key: PageDown, mods: Shift, chars: "\x1b[6;2~" }
|
||||
- { key: PageDown, mods: Control, chars: "\x1b[6;5~" }
|
||||
- { key: PageDown, chars: "\x1b[6~" }
|
||||
- { key: Left, mods: Shift, chars: "\x1b[1;2D" }
|
||||
- { key: Left, mods: Control, chars: "\x1b[1;5D" }
|
||||
- { key: Left, mods: Alt, chars: "\x1b[1;3D" }
|
||||
- { key: Left, chars: "\x1b[D", mode: ~AppCursor }
|
||||
- { key: Left, chars: "\x1bOD", mode: AppCursor }
|
||||
- { key: Right, mods: Shift, chars: "\x1b[1;2C" }
|
||||
- { key: Right, mods: Control, chars: "\x1b[1;5C" }
|
||||
- { key: Right, mods: Alt, chars: "\x1b[1;3C" }
|
||||
- { key: Right, chars: "\x1b[C", mode: ~AppCursor }
|
||||
- { key: Right, chars: "\x1bOC", mode: AppCursor }
|
||||
- { key: Up, mods: Shift, chars: "\x1b[1;2A" }
|
||||
- { key: Up, mods: Control, chars: "\x1b[1;5A" }
|
||||
- { key: Up, mods: Alt, chars: "\x1b[1;3A" }
|
||||
- { key: Up, chars: "\x1b[A", mode: ~AppCursor }
|
||||
- { key: Up, chars: "\x1bOA", mode: AppCursor }
|
||||
- { key: Down, mods: Shift, chars: "\x1b[1;2B" }
|
||||
- { key: Down, mods: Control, chars: "\x1b[1;5B" }
|
||||
- { key: Down, mods: Alt, chars: "\x1b[1;3B" }
|
||||
- { key: Down, chars: "\x1b[B", mode: ~AppCursor }
|
||||
- { key: Down, chars: "\x1bOB", mode: AppCursor }
|
||||
- { key: Tab, mods: Shift, chars: "\x1b[Z" }
|
||||
- { key: F1, chars: "\x1bOP" }
|
||||
- { key: F2, chars: "\x1bOQ" }
|
||||
- { key: F3, chars: "\x1bOR" }
|
||||
- { key: F4, chars: "\x1bOS" }
|
||||
- { key: F5, chars: "\x1b[15~" }
|
||||
- { key: F6, chars: "\x1b[17~" }
|
||||
- { key: F7, chars: "\x1b[18~" }
|
||||
- { key: F8, chars: "\x1b[19~" }
|
||||
- { key: F9, chars: "\x1b[20~" }
|
||||
- { key: F10, chars: "\x1b[21~" }
|
||||
- { key: F11, chars: "\x1b[23~" }
|
||||
- { key: F12, chars: "\x1b[24~" }
|
||||
- { key: Back, chars: "\x7f" }
|
||||
- { key: Back, mods: Alt, chars: "\x1b\x7f" }
|
||||
- { key: Insert, chars: "\x1b[2~" }
|
||||
- { key: Delete, chars: "\x1b[3~" }
|
||||
|
||||
# Mouse bindings
|
||||
#
|
||||
# Currently doesn't support modifiers. Both the `mouse` and `action` fields must
|
||||
# be specified.
|
||||
#
|
||||
# Values for `mouse`:
|
||||
# - Middle
|
||||
# - Left
|
||||
# - Right
|
||||
# - Numeric identifier such as `5`
|
||||
#
|
||||
# Values for `action`:
|
||||
# - Paste
|
||||
# - PasteSelection
|
||||
# - Copy (TODO)
|
||||
mouse_bindings:
|
||||
- { mouse: Middle, action: PasteSelection }
|
||||
|
||||
mouse:
|
||||
double_click: { threshold: 300 }
|
||||
triple_click: { threshold: 300 }
|
||||
|
||||
selection:
|
||||
semantic_escape_chars: ",│`|:\"' ()[]{}<>"
|
||||
|
||||
hide_cursor_when_typing: false
|
||||
|
||||
# Shell
|
||||
#
|
||||
# You can set shell.program to the path of your favorite shell, e.g. /bin/fish.
|
||||
# Entries in shell.args are passed unmodified as arguments to the shell.
|
||||
shell:
|
||||
program: /bin/bash
|
||||
args:
|
||||
- --login
|
@ -0,0 +1,7 @@
|
||||
#!/bin/bash
|
||||
killall -q polybar
|
||||
while pgrep -x polybar >/dev/null; do sleep 1; done
|
||||
|
||||
MONITOR=DP-0 polybar bar1 &
|
||||
MONITOR=DVI-I-1-1 polybar bar1 &
|
||||
MONITOR=DVI-I-2-2 polybar bar1 &
|
@ -0,0 +1,210 @@
|
||||
servers = (
|
||||
{
|
||||
address = "chat.freenode.net";
|
||||
chatnet = "freenode";
|
||||
port = "7000";
|
||||
use_ssl = "yes";
|
||||
ssl_verify = "yes";
|
||||
ssl_capath = "/etc/ssl/certs";
|
||||
autoconnect = "no";
|
||||
}
|
||||
);
|
||||
|
||||
channels = (
|
||||
{ name = "#plone"; chatnet = "freenode"; autojoin = "yes"; },
|
||||
{ name = "#plone-framework"; chatnet = "freenode"; autojoin = "yes"; },
|
||||
{ name = "#nixos"; chatnet = "freenode"; autojoin = "yes"; },
|
||||
{ name = "#vimperator"; chatnet = "freenode"; autojoin = "yes"; }
|
||||
);
|
||||
|
||||
aliases = {
|
||||
J = "join";
|
||||
WJOIN = "join -window";
|
||||
WQUERY = "query -window";
|
||||
LEAVE = "part";
|
||||
BYE = "quit";
|
||||
EXIT = "quit";
|
||||
SIGNOFF = "quit";
|
||||
DESCRIBE = "action";
|
||||
DATE = "time";
|
||||
HOST = "userhost";
|
||||
LAST = "lastlog";
|
||||
SAY = "msg *";
|
||||
WI = "whois";
|
||||
WII = "whois $0 $0";
|
||||
WW = "whowas";
|
||||
W = "who";
|
||||
N = "names";
|
||||
M = "msg";
|
||||
T = "topic";
|
||||
C = "clear";
|
||||
CL = "clear";
|
||||
K = "kick";
|
||||
KB = "kickban";
|
||||
KN = "knockout";
|
||||
BANS = "ban";
|
||||
B = "ban";
|
||||
MUB = "unban *";
|
||||
UB = "unban";
|
||||
IG = "ignore";
|
||||
UNIG = "unignore";
|
||||
SB = "scrollback";
|
||||
UMODE = "mode $N";
|
||||
WC = "window close";
|
||||
WN = "window new hide";
|
||||
SV = "say Irssi $J ($V) - http://irssi.org/";
|
||||
GOTO = "sb goto";
|
||||
CHAT = "dcc chat";
|
||||
RUN = "SCRIPT LOAD";
|
||||
CALC = "exec - if command -v bc >/dev/null 2>&1\\; then printf '%s=' '$*'\\; echo '$*' | bc -l\\; else echo bc was not found\\; fi";
|
||||
SBAR = "STATUSBAR";
|
||||
INVITELIST = "mode $C +I";
|
||||
Q = "QUERY";
|
||||
"MANUAL-WINDOWS" = "set use_status_window off;set autocreate_windows off;set autocreate_query_level none;set autoclose_windows off;set reuse_unused_windows on;save";
|
||||
EXEMPTLIST = "mode $C +e";
|
||||
ATAG = "WINDOW SERVER";
|
||||
UNSET = "set -clear";
|
||||
RESET = "set -default";
|
||||
};
|
||||
|
||||
statusbar = {
|
||||
# formats:
|
||||
# when using {templates}, the template is shown only if it's argument isn't
|
||||
# empty unless no argument is given. for example {sb} is printed always,
|
||||
# but {sb $T} is printed only if $T isn't empty.
|
||||
|
||||
items = {
|
||||
# start/end text in statusbars
|
||||
barstart = "{sbstart}";
|
||||
barend = "{sbend}";
|
||||
|
||||
topicbarstart = "{topicsbstart}";
|
||||
topicbarend = "{topicsbend}";
|
||||
|
||||
# treated "normally", you could change the time/user name to whatever
|
||||
time = "{sb $Z}";
|
||||
user = "{sb {sbnickmode $cumode}$N{sbmode $usermode}{sbaway $A}}";
|
||||
|
||||
# treated specially .. window is printed with non-empty windows,
|
||||
# window_empty is printed with empty windows
|
||||
window = "{sb $winref:$tag/$itemname{sbmode $M}}";
|
||||
window_empty = "{sb $winref{sbservertag $tag}}";
|
||||
prompt = "{prompt $[.15]itemname}";
|
||||
prompt_empty = "{prompt $winname}";
|
||||
topic = " $topic";
|
||||
topic_empty = " Irssi v$J - http://www.irssi.org";
|
||||
|
||||
# all of these treated specially, they're only displayed when needed
|
||||
lag = "{sb Lag: $0-}";
|
||||
act = "{sb Act: $0-}";
|
||||
more = "-- more --";
|
||||
};
|
||||
|
||||
# there's two type of statusbars. root statusbars are either at the top
|
||||
# of the screen or at the bottom of the screen. window statusbars are at
|
||||
# the top/bottom of each split window in screen.
|
||||
default = {
|
||||
# the "default statusbar" to be displayed at the bottom of the window.
|
||||
# contains all the normal items.
|
||||
window = {
|
||||
disabled = "no";
|
||||
|
||||
# window, root
|
||||
type = "window";
|
||||
# top, bottom
|
||||
placement = "bottom";
|
||||
# number
|
||||
position = "1";
|
||||
# active, inactive, always
|
||||
visible = "active";
|
||||
|
||||
# list of items in statusbar in the display order
|
||||
items = {
|
||||
barstart = { priority = "100"; };
|
||||
time = { };
|
||||
user = { };
|
||||
window = { };
|
||||
window_empty = { };
|
||||
lag = { priority = "-1"; };
|
||||
act = { priority = "10"; };
|
||||
more = { priority = "-1"; alignment = "right"; };
|
||||
barend = { priority = "100"; alignment = "right"; };
|
||||
vim_mode = { };
|
||||
vim_windows = { };
|
||||
};
|
||||
};
|
||||
|
||||
# statusbar to use in inactive split windows
|
||||
window_inact = {
|
||||
type = "window";
|
||||
placement = "bottom";
|
||||
position = "1";
|
||||
visible = "inactive";
|
||||
items = {
|
||||
barstart = { priority = "100"; };
|
||||
window = { };
|
||||
window_empty = { };
|
||||
more = { priority = "-1"; alignment = "right"; };
|
||||
barend = { priority = "100"; alignment = "right"; };
|
||||
};
|
||||
};
|
||||
|
||||
# we treat input line as yet another statusbar :) It's possible to
|
||||
# add other items before or after the input line item.
|
||||
|
||||
# topicbar
|
||||
topic = {
|
||||
type = "root";
|
||||
placement = "top";
|
||||
position = "1";
|
||||
visible = "always";
|
||||
items = {
|
||||
topicbarstart = { priority = "100"; };
|
||||
topic = { };
|
||||
topic_empty = { };
|
||||
topicbarend = { priority = "100"; alignment = "right"; };
|
||||
};
|
||||
};
|
||||
prompt = {
|
||||
items = {
|
||||
uberprompt = { priority = "-1"; };
|
||||
input = { priority = "10"; };
|
||||
};
|
||||
position = "100";
|
||||
};
|
||||
};
|
||||
};
|
||||
settings = {
|
||||
core = {
|
||||
real_name = "solzhenitsyn";
|
||||
user_name = "ivan";
|
||||
nick = "deep";
|
||||
};
|
||||
"fe-text" = {
|
||||
actlist_sort = "refnum";
|
||||
term_force_colors = "yes";
|
||||
autostick_split_windows = "yes";
|
||||
};
|
||||
"fe-common/core" = {
|
||||
autocreate_own_query = "yes";
|
||||
autocreate_query_level = "DCCMSGS";
|
||||
use_status_window = "no";
|
||||
use_msgs_window = "yes";
|
||||
autoclose_windows = "no";
|
||||
reuse_unused_windows = "yes";
|
||||
print_active_channel = "yes";
|
||||
autolog = "yes";
|
||||
autolog_path = "~/.irssi/logs/$tag/%Y-%m-%d/$0.log";
|
||||
};
|
||||
"fe-common/irc" = { show_away_once = "yes"; };
|
||||
"irc/core" = { channel_sync = "no"; };
|
||||
};
|
||||
hilights = ( { text = "datetimewidget"; nick = "yes"; word = "yes"; } );
|
||||
logs = { };
|
||||
ignores = (
|
||||
{ level = "JOINS"; servertag = "freenode"; },
|
||||
{ level = "NICKS"; servertag = "freenode"; },
|
||||
{ level = "PARTS"; servertag = "freenode"; },
|
||||
{ level = "QUITS"; servertag = "freenode"; }
|
||||
);
|
||||
chatnets = { bitlbee = { type = "IRC"; }; freenode = { type = "IRC"; }; };
|
@ -0,0 +1,19 @@
|
||||
[xin_0]
|
||||
file=~/.config/nitrogen/painted_plains_3840x2160.jpg
|
||||
mode=2
|
||||
bgcolor=#000000
|
||||
|
||||
[xin_1]
|
||||
file=~/.config/nitrogen/painted_plains_3840x2160.jpg
|
||||
mode=2
|
||||
bgcolor=#000000
|
||||
|
||||
[xin_2]
|
||||
file=~/.config/nitrogen/painted_plains_3840x2160.jpg
|
||||
mode=2
|
||||
bgcolor=#000000
|
||||
|
||||
[:1.2]
|
||||
file=~/.config/nitrogen/painted_plains_3840x2160.jpg
|
||||
mode=2
|
||||
bgcolor=#000000
|
@ -1,8 +1,8 @@
|
||||
[geometry]
|
||||
posx=0
|
||||
posx=3840
|
||||
posy=24
|
||||
sizex=1916
|
||||
sizey=2134
|
||||
sizex=3836
|
||||
sizey=2089
|
||||
|
||||
[nitrogen]
|
||||
view=icon
|
After Width: | Height: | Size: 6.1 MiB |
@ -0,0 +1,7 @@
|
||||
Home ~/
|
||||
Projects ~/Projects
|
||||
Work ~/Projects/work
|
||||
Documents ~/Documents
|
||||
Configs ~/.config
|
||||
Shell Extensions ~/.shell_extensions
|
||||
Downloads ~/Desktop
|
@ -0,0 +1,46 @@
|
||||
git://github.com/tpope/vim-pathogen.git
|
||||
git://github.com/tpope/vim-fugitive.git
|
||||
git://github.com/tpope/vim-dispatch.git
|
||||
git://github.com/Valloric/YouCompleteMe.git
|
||||
git://github.com/nathanaelkane/vim-indent-guides.git
|
||||
git://github.com/airblade/vim-gitgutter.git
|
||||
git://github.com/fholgado/minibufexpl.vim.git
|
||||
git://github.com/bling/vim-airline.git
|
||||
git://github.com/fatih/vim-go.git
|
||||
git://github.com/scrooloose/nerdtree.git
|
||||
git://github.com/tpope/vim-dadbod.git
|
||||
# utils
|
||||
git://github.com/scrooloose/syntastic.git
|
||||
git://github.com/easymotion/vim-easymotion.git
|
||||
git://github.com/ervandew/supertab.git
|
||||
git://github.com/tpope/vim-repeat.git
|
||||
git://github.com/tpope/vim-surround.git
|
||||
git://github.com/kien/ctrlp.vim.git
|
||||
git://github.com/vim-scripts/tComment
|
||||
# syntax
|
||||
git://github.com/cakebaker/scss-syntax.vim.git
|
||||
git://github.com/pangloss/vim-javascript.git
|
||||
git://github.com/vim-ruby/vim-ruby.git
|
||||
git://github.com/vim-scripts/matchit.zip.git
|
||||
git://github.com/oscarh/vimerl.git
|
||||
git://github.com/sukima/xmledit.git
|
||||
git://github.com/mxw/vim-jsx.git
|
||||
git://github.com/gorodinskiy/vim-coloresque.git
|
||||
git://github.com/groenewege/vim-less.git
|
||||
git://github.com/tpope/vim-markdown.git
|
||||
git://github.com/tpope/vim-haml.git
|
||||
#themes
|
||||
git://github.com/wdhg/dragon-energy.git
|
||||
git://github.com/FrancescoMagliocco/CmptrClr.git
|
||||
git://github.com/sainnhe/gruvbox-material.git
|
||||
git://github.com/cjgajard/patagonia-vim.git
|
||||
git://github.com/ciaranm/inkpot.git
|
||||
git://github.com/lsdr/monokai.git
|
||||
git://github.com/chriskempson/vim-tomorrow-theme.git
|
||||
git://github.com/vim-scripts/vilight.vim.git
|
||||
git://github.com/dsolstad/vim-wombat256i.git
|
||||
git://github.com/altercation/vim-colors-solarized.git
|
||||
git://github.com/nanotech/jellybeans.vim.git
|
||||
git://github.com/vim-scripts/ecostation.git
|
||||
git://github.com/vim-scripts/rdark.git
|
||||
git://github.com/trevorrjohn/vim-obsidian.git
|
@ -0,0 +1,17 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
if [ -f "$PWD/makefile" ] && [ ! -z "$(cat $PWD/makefile | grep 'lint:')" ]; then
|
||||
echo "lint rule found in $PWD/makefile..."
|
||||
make lint
|
||||
elif [ -f "$PWD/package.json" ] && [ ! -z "$(cat $PWD/package.json | grep '\"lint\"')" ]; then
|
||||
echo "running npm run lint..."
|
||||
npm run lint
|
||||
fi
|
||||
|
||||
if [ -f "$PWD/makefile" ] && [ ! -z "$(cat $PWD/makefile | grep 'test:')" ]; then
|
||||
echo "test rule found in $PWD/makefile..."
|
||||
make test
|
||||
elif [ -f "$PWD/package.json" ] && [ ! -z "$(cat $PWD/package.json | grep '\"test\"')" ]; then
|
||||
echo "running npm run test..."
|
||||
npm run test
|
||||
fi
|
@ -0,0 +1,14 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# If the following text is found anywhere in the source for HEAD, we will prevent pushing
|
||||
dont_push_flag="DONT PUSH ME"
|
||||
|
||||
flag_found=`git grep --color "$dont_push_flag" HEAD`
|
||||
if [ -n "$flag_found" ]
|
||||
then
|
||||
# Display which commit the first occurence of the flag was found and exit failure
|
||||
commit=`git log --pretty=format:'%Cred%h%Creset' -S "$dont_push_flag" | tail -n1`
|
||||
echo "Found $flag_found, first occurence was in $commit, not pushing"
|
||||
exit 1
|
||||
fi
|
||||
exit 0
|
@ -0,0 +1,31 @@
|
||||
|
||||
# ^ [issue #id] [Add/Fix/Remove/Update/Refactor/Document] [summary] ^
|
||||
|
||||
# Why is it necessary? (Bug fix, feature, improvements?)
|
||||
|
||||
# How does the change address the issue?
|
||||
|
||||
# What side effects does this change have?
|
||||
|
||||
# Rationale:
|
||||
# Capitalized, short (50 chars or less) summary
|
||||
# More detailed explanatory text, if necessary. Wrap it to about 72
|
||||
# characters or so. In some contexts, the first line is treated as the
|
||||
# subject of an email and the rest of the text as the body. The blank
|
||||
# line separating the summary from the body is critical (unless you omit
|
||||
# the body entirely); tools like rebase can get confused if you run the
|
||||
# two together.
|
||||
#
|
||||
# Write your commit message in the imperative: "Fix bug" and not "Fixed bug"
|
||||
# or "Fixes bug." This convention matches up with commit messages generated
|
||||
# by commands like git merge and git revert.
|
||||
#
|
||||
# Further paragraphs come after blank lines.
|
||||
#
|
||||
# - Bullet points are okay, too
|
||||
#
|
||||
# - Typically a hyphen or asterisk is used for the bullet, followed by a
|
||||
# single space, with blank lines in between, but conventions vary here
|
||||
#
|
||||
# - Use a hanging indent
|
||||
# Read more @ https://tbaggery.com/2008/04/19/a-note-about-git-commit-messages.html
|
@ -0,0 +1,42 @@
|
||||
#!/bin/bash
|
||||
# vim: set ft=sh
|
||||
alias cdp="cd -"
|
||||
alias ..='cd ..'
|
||||
alias pd="pushd $1"
|
||||
alias tx="tmux -f ~/.config/tmux/.tmux.conf"
|
||||
|
||||
# list files
|
||||
alias ll='ls -hGla'
|
||||
|
||||
#rake
|
||||
alias bake='bundle exec rake'
|
||||
|
||||
#tools
|
||||
alias resrc='source ~/.bash_aliases && source ~/.bashrc && source ~/.profile'
|
||||
alias role='whoami -groups -fo list | grep -i'
|
||||
alias fu='find ./ -type f -print0 | xargs -0 grep -n $1'
|
||||
|
||||
#git
|
||||
alias gs='git status'
|
||||
|
||||
alias gm='git merge --ff-only'
|
||||
alias gpr='git pull --rebase'
|
||||
alias gmt='git mergetool'
|
||||
alias grc='git rebase --continue'
|
||||
alias gk='git fetch origin; git remote prune origin; gitk --all &'
|
||||
alias gl='git log --pretty=format:"%h %ar by %an: %s"'
|
||||
|
||||
# Get week number
|
||||
alias week='date +%V'
|
||||
|
||||
# Stopwatch
|
||||
alias timer='echo "Timer started. Stop with Ctrl-D." && date && time cat && date'
|
||||
|
||||
# IP addresses
|
||||
alias ip="dig +short myip.opendns.com @resolver1.opendns.com"
|
||||
alias localip="ipconfig getifaddr en0"
|
||||
alias ips="ifconfig -a | grep -o 'inet6\? \(addr:\)\?\s\?\(\(\([0-9]\+\.\)\{3\}[0-9]\+\)\|[a-fA-F0-9:]\+\)' | awk '{ sub(/inet6? (addr:)? ?/, \"\"); print }'"
|
||||
|
||||
# Kill all the tabs in Chrome to free up memory
|
||||
# [C] explained: http://www.commandlinefu.com/commands/view/402/exclude-grep-from-your-grepped-output-of-ps-alias-included-in-description
|
||||
alias chromekill="ps ux | grep '[C]hrome Helper --type=renderer' | grep -v extension-process | tr -s ' ' | cut -d ' ' -f2 | xargs kill"
|
@ -0,0 +1,7 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Add an "alert" alias for long running commands. Use like so:
|
||||
# sleep 10; alert
|
||||
alias alert='notify-send --urgency=low -i "$([ $? = 0 ] && echo terminal || echo error)" "$(history|tail -n1|sed -e '\''s/^\s*[0-9]\+\s*//;s/[;&|]\s*alert$//'\'')"'
|
||||
|
||||
|
@ -0,0 +1,27 @@
|
||||
#!/bin/bash
|
||||
|
||||
function tunnel(){
|
||||
if [[ -z $1 ]]; then
|
||||
echo "Takes an ssh config host name and starts an SSH tunnel"
|
||||
echo "$1 required: name of an ssh tunnel host"
|
||||
echo "$2 optional: run the tunnel as a background job if defined"
|
||||
return -1
|
||||
fi
|
||||
|
||||
if [[ -z $2 ]]; then
|
||||
sudo ssh -f -N $1
|
||||
else
|
||||
sudo ssh -f -N $1 &
|
||||
fi
|
||||
}
|
||||
|
||||
function pubkey(){
|
||||
if [[ -z $1 ]]; then
|
||||
echo "Takes a path to a private key and prints a compatible public key to stdout"
|
||||
echo "$1 required: path to a private key"
|
||||
return -1
|
||||
fi
|
||||
|
||||
|
||||
ssh-keygen -y -f $1
|
||||
}
|
@ -1,3 +1,4 @@
|
||||
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<key name="Software">
|
||||
<key name="ConEmu">
|
Binary file not shown.
@ -0,0 +1,40 @@
|
||||
@font-face {
|
||||
font-family: 'Fira Code';
|
||||
src: url('woff2/FiraCode-Light.woff2') format('woff2'),
|
||||
url("woff/FiraCode-Light.woff") format("woff");
|
||||
font-weight: 300;
|
||||
font-style: normal;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Fira Code';
|
||||
src: url('woff2/FiraCode-Regular.woff2') format('woff2'),
|
||||
url("woff/FiraCode-Regular.woff") format("woff");
|
||||
font-weight: 400;
|
||||
font-style: normal;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Fira Code';
|
||||
src: url('woff2/FiraCode-Medium.woff2') format('woff2'),
|
||||
url("woff/FiraCode-Medium.woff") format("woff");
|
||||
font-weight: 500;
|
||||
font-style: normal;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Fira Code';
|
||||
src: url('woff2/FiraCode-Bold.woff2') format('woff2'),
|
||||
url("woff/FiraCode-Bold.woff") format("woff");
|
||||
font-weight: 700;
|
||||
font-style: normal;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: 'Fira Code VF';
|
||||
src: url('woff2/FiraCode-VF.woff2') format('woff2-variations'),
|
||||
url('woff/FiraCode-VF.woff') format('woff-variations');
|
||||
/* font-weight requires a range: https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_Fonts/Variable_Fonts_Guide#Using_a_variable_font_font-face_changes */
|
||||
font-weight: 300 700;
|
||||
font-style: normal;
|
||||
}
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -0,0 +1,84 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width,initial-scale=1.0">
|
||||
<title>Fira Code Specimen</title>
|
||||
|
||||
<link rel="stylesheet" href="fira_code.css">
|
||||
<style>
|
||||
body { font: 14px/1.5em "Fira Code"; }
|
||||
.code {
|
||||
font-feature-settings: "calt" 1; /* Enable ligatures for IE 10+, Edge */
|
||||
text-rendering: optimizeLegibility; /* Force ligatures for Webkit, Blink, Gecko */
|
||||
width: 30em;
|
||||
margin: 5em auto;
|
||||
white-space: pre-wrap;
|
||||
word-break: break-all;
|
||||
}
|
||||
.light { font-weight: 300; }
|
||||
.regular { font-weight: 400; }
|
||||
.medium { font-weight: 500; }
|
||||
.bold { font-weight: 700; }
|
||||
.variable { font-family: 'Fira Code VF'; font-variation-settings: 'wght' 400; }
|
||||
i { font-style: normal; color: #c33; }
|
||||
b { font-weight: inherit; color: #c33; }
|
||||
</style>
|
||||
<script type="text/javascript">
|
||||
function onWeightChange(weight) {
|
||||
// code_variable.style['font-weight'] = weight;
|
||||
code_variable.style['font-variation-settings'] = "'wght' " + weight;
|
||||
span_wght.innerText = weight;
|
||||
}
|
||||
</script>
|
||||
<body>
|
||||
|
||||
<div class="code light"><b># Fira Code Light</b>
|
||||
|
||||
take = (n, [x, <i>...</i>xs]:list) <i>--></i>
|
||||
| n <i><=</i> 0 <i>=></i> []
|
||||
| empty list <i>=></i> []
|
||||
| otherwise <i>=></i> [x] <i>++</i> take n-1, xs
|
||||
|
||||
last3 = reverse <i>>></i> take 3 <i>>></i> reverse</div>
|
||||
|
||||
|
||||
<div class="code regular"><b># Fira Code Regular</b>
|
||||
|
||||
take = (n, [x, <i>...</i>xs]:list) <i>--></i>
|
||||
| n <i><=</i> 0 <i>=></i> []
|
||||
| empty list <i>=></i> []
|
||||
| otherwise <i>=></i> [x] <i>++</i> take n-1, xs
|
||||
|
||||
last3 = reverse <i>>></i> take 3 <i>>></i> reverse</div>
|
||||
|
||||
|
||||
<div class="code medium"><b># Fira Code Medium</b>
|
||||
|
||||
take = (n, [x, <i>...</i>xs]:list) <i>--></i>
|
||||
| n <i><=</i> 0 <i>=></i> []
|
||||
| empty list <i>=></i> []
|
||||
| otherwise <i>=></i> [x] <i>++</i> take n-1, xs
|
||||
|
||||
last3 = reverse <i>>></i> take 3 <i>>></i> reverse</div>
|
||||
|
||||
|
||||
<div class="code bold"><b># Fira Code Bold</b>
|
||||
|
||||
take = (n, [x, <i>...</i>xs]:list) <i>--></i>
|
||||
| n <i><=</i> 0 <i>=></i> []
|
||||
| empty list <i>=></i> []
|
||||
| otherwise <i>=></i> [x] <i>++</i> take n-1, xs
|
||||
|
||||
last3 = reverse <i>>></i> take 3 <i>>></i> reverse</div>
|
||||
|
||||
<div id="code_variable" class="code variable"><b># Fira Code Variable</b>
|
||||
|
||||
<input type="range" min="300" max="700" value="400" step="10" style="width: 300px;" oninput="onWeightChange(this.value)" onchange="onWeightChange(this.value)"> <span id="span_wght">400</span>
|
||||
|
||||
take = (n, [x, <i>...</i>xs]:list) <i>--></i>
|
||||
| n <i><=</i> 0 <i>=></i> []
|
||||
| empty list <i>=></i> []
|
||||
| otherwise <i>=></i> [x] <i>++</i> take n-1, xs
|
||||
|
||||
last3 = reverse <i>>></i> take 3 <i>>></i> reverse</div>
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
File diff suppressed because one or more lines are too long
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in new issue