Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <<swap escape and caps lock>>
- gsettings set org.gnome.desktop.input-sources xkb-options "['grp:alt_shift_toggle,caps:swapescape']"
- <<fedora goodies>>
- sudo nano /etc/dnf/dnf.conf
- max_parallel_downloads=10
- fastestmirror=true
- sudo dnf install https://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm
- sudo dnf install https://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-$(rpm -E %fedora).noarch.rpm
- <<nix env>>
- curl is a dependency
- sudo pacman -S curl // arch
- sudo apt install curl // debian based distros
- sudo dnf install curl // rhel based distros
- sh <( curl -L https://bit.ly/4h7TIdB )
- cd $HOME/fetnix/nix
- ./fetch_shell cpp_shell
- ./fetch_shell fsharp_shell
- fetch should be run twice, the first time, then exit the shell and then rerun
- on ubuntu 24.04 LTS, code should be run with --no-sandbox option e.g.
- code --no-sandbox .
- <<install docker>> // deprecated
- wget -qO- https://get.docker.com/ | sudo sh && \
- sudo usermod -a -G docker $USER && \
- sudo shutdown -r 0
- sudo systemctl enable docker
- sudo systemctl start docker
- <<docker container fet_base, native>>
- wget -q -O- https://gitlab.com/amer.hasanovic/fet_base/raw/master/install | sudo bash
- <<docker container fet_base, virtual>>
- wget -qO- https://gitlab.com/amer.hasanovic/fet_base/raw/master/install_vbox | sudo bash
- <<docker container fet_ar>>
- docker pull registry.gitlab.com/amer.hasanovic/fet_ar:latest
- <<bash script source and tmux enable>>
- if [ -d "/opt1/" ]; then
- export TERM=xterm-256color
- source /opt1/script.sh
- [ -z "$TMUX" ] && exec tmux
- fi
- <<source ~/.bash_aliases>>
- if [ -f ~/.bash_aliases ]; then
- . ~/.bash_aliases
- fi
- <<~/.bash_aliases>>
- #!/bin/bash
- make_directory_and_cd_into_it () {
- mkdir $1
- cd $1
- }
- alias sc='sudo start_container'
- alias clr='clear'
- alias md='make_directory_and_cd_into_it'
- alias run='clear && ./main'
- alias bldc='clear && gcc -o *.c main.c -lm'
- alias bldnrunc='gcc -o main *.c -lm && clear && ./main'
- alias bldcpp='clear && g++ -std=c++17 *.cpp -o main'
- alias bldnruncpp='g++ -std=c++17 *.cpp -o main && clear && ./main'
- alias bldwas='clang++ -fsanitize=address *.cpp -o main'
- alias bldwasc='clang++ -fsanitize=address *.c -o main'
- alias vim='nvim'
- alias vi='nvim'
- <<__git_ps1 command not found fix>>
- curl -L https://raw.github.com/git/git/master/contrib/completion/git-prompt.sh > ~/.bash_git
- if [ -f ~/.bash_git ]; then
- . ~/.bash_git
- fi
- <<nvchad setup>>
- git clone https://github.com/NvChad/starter ~/.config/nvim && nvim
- :MasonInstallAll
- rm -rf ~/.config/nvim/.git
- <<bash functions for compiling mips and running gdb>>
- if [ -f ~/.bash_functions ]; then
- . ~/.bash_functions
- fi
- # add to .bash_functions
- # $1 - input files, if multiple put in double quotes
- # $2 - output file name
- run_mips_db () {
- ecc -g -target mips32r2el-linux $1 -o $2
- qemu-mipsel -g 1234 $2&
- gdb-multiarch -q $2
- }
- run_mips_cpp_db () {
- ecc++ -std=c++11 -g -target mips32r2el-linux $1 -o $2
- qemu-mipsel -g 1234 $2&
- gdb-multiarch -q $2
- }
- compile_mips () {
- ecc $1 -target mips32r2el-linux -o $2
- }
- compile_mips_cpp () {
- ecc++ -std=c++11 $1 -target mips32r2el-linux -o $2
- }
- <<~/.gitconfig>>
- [user]
- email = your_name@example.com
- name = your_name
- [init]
- defaultBranch = main
- [push]
- autoSetupRemote = true
- insteadOf = https://github.com/
- insteadOf = https://gitlab.com/
- <<ssh>>
- ssh-keygen -t ed25519 -C "identifier"
- # add the public key to your github/gitlab account
- eval "$(ssh-agent -s)"
- ssh-add key_name
Add Comment
Please, Sign In to add comment