This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
alias vi="nvim" | |
alias vim="nvim" | |
alias view="nvim -R" | |
alias vimdiff="nvim -d" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
######## | |
mkdir /tmp/dpkg_hist | |
rsync -av /var/log/dpkg.log* /tmp/dpkg_hist | |
pushd /tmp/dpkg_hist | |
gunzip *.gz | |
for f in $(ls -rt); do | |
cat $f | egrep 'install|remove' >>$HOME/hist.log |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
docker pull ubuntu:20.04 | |
docker run -it --rm ubuntu:20.04 bash | |
set -o vi | |
cd $HOME | |
apt update && apt dist-upgrade -y && apt autoclean -y && apt autoremove -y | |
apt install git sudo vim-nox -y | |
mkdir src && cd src | |
git clone https://github.com/mikemadden42/ripley.git |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cargo clippy -- -Wclippy::pedantic -Wrustdoc::private_intra_doc_links -Aclippy::single-match-else -Aclippy::default-trait-access -Aclippy::missing-panics-doc | |
cargo clippy -- -D warnings -A deprecated |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cmake -B build -DCMAKE_BUILD_TYPE=Release | |
cmake --build build --config Release | |
ctest -C Release | |
cmake -B build -DCMAKE_BUILD_TYPE=Release | |
cmake --build build --config Release -j | |
ctest -C Release | |
cmake -B build -DCMAKE_BUILD_TYPE=Release | |
time cmake --build build --config Release --parallel |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <boost/filesystem.hpp> | |
#include <iostream> | |
// g++ -o boo boo.cc -lboost_filesystem | |
// clang++ -o boo boo.cc -lboost_filesystem | |
int main() { | |
boost::filesystem::path p("/"); | |
auto freeSpace = boost::filesystem::space(p).free; | |
std::cout << freeSpace << " Bytes free" << std::endl; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/zsh | |
echo "system_profiler SPHardwareDataType:" | |
system_profiler SPHardwareDataType | |
echo | |
echo "hostinfo:" | |
hostinfo | |
echo |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/zsh | |
# With go 1.17 use go install to install binaries: | |
# https://golang.org/doc/go-get-install-deprecation | |
# TODO: change many of these 'go get' to 'go install'. | |
# START UTILS | |
projects=( | |
github.com/BurntSushi/toml/cmd/tomlv | |
github.com/ChimeraCoder/gojson/gojson |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
REM START UTILS | |
go get -u -ldflags "-s -w" github.com/BurntSushi/toml | |
go get -u -ldflags "-s -w" github.com/BurntSushi/toml/cmd/tomlv | |
go get -u -ldflags "-s -w" github.com/ChimeraCoder/gojson/gojson | |
go get -u -ldflags "-s -w" github.com/andrewkroh/gvm/cmd/gvm | |
go get -u -ldflags "-s -w" github.com/asciimoo/wuzz | |
go get -u -ldflags "-s -w" github.com/boyter/scc | |
set GO111MODULE=on | |
go get -ldflags "-s -w" github.com/charmbracelet/glow | |
set GO111MODULE= |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
rustup self update | |
rustup update | |
rustup component add clippy | |
rustup component add rls rust-analysis rust-src | |
rustup component add rustfmt |
NewerOlder