Coder Social home page Coder Social logo

dotfiles's Introduction

dotfiles

0. Install Command Line Tools

xcode-select --install

1. Install brew

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

2. Setup Git

Install git:

brew install git

Add git credentials:

git config --global user.name "Andrey Ivanov"
git config --global user.email "[email protected]"

Generate ssh keys:

# Generate new ssh key
ssh-keygen -t ed25519  -C "[email protected]"

# Start the ssh-agent in the background
eval "$(ssh-agent -s)"

# Add your SSH private key to the ssh-agent
ssh-add ~/.ssh/id_ed25519

Add ssh-key to GitHub account:

# Copy ssh key to clipboard
cat ~/.ssh/id_ed25519.pub

3. Copy dotfiles

from https://github.com/ivnvxd/dotfiles

git clone [email protected]:ivnvxd/dotfiles.git ~

4. Install everything from  ~/Brewfile

brew bundle install

To create a Brewfile:

brew bundle dump

5. Setup zsh shell

Install oh-my-zsh:

sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"

Install Powerlevel10k:

git clone https://github.com/romkatv/powerlevel10k.git $ZSH_CUSTOM/themes/powerlevel10k

# configure Pure theme:
p10k configure

Install plugins:

git clone https://github.com/zsh-users/zsh-completions ${ZSH_CUSTOM:-${ZSH:-~/.oh-my-zsh}/custom}/plugins/zsh-completions
git clone https://github.com/zsh-users/zsh-history-substring-search ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-history-substring-search
git clone https://github.com/zdharma-continuum/fast-syntax-highlighting.git \
  ${ZSH_CUSTOM:-$HOME/.oh-my-zsh/custom}/plugins/fast-syntax-highlighting
git clone https://github.com/zsh-users/zsh-autosuggestions ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions

5.1 Setup fish shell

Add fish to the shell list:

sudo bash -c 'echo $(which fish) >> /etc/shells'

(optional) make fish the default shell:

chsh -s $(which fish)

(optional) Uncomment in .config/tmux/tmux.conf:

set-option -g default-shell "/opt/homebrew/bin/fish"

Install fish pure theme:

fisher install rafaelrinaldi/pure

6. Setup tmux

Install Tmux Plugin Manager:

git clone https://github.com/tmux-plugins/tpm ~/.tmux/plugins/tpm

Install plugins with <prefix> I

7. Setup Vim

Install Plug

curl -fLo ~/.vim/autoload/plug.vim --create-dirs \
    https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim

:PlugInstall to install plugins.

8. Setup Poetry

Either brew or:

curl -sSL https://install.python-poetry.org | python3 -

Configure Poetry to create vitual env inside each project

poetry config virtualenvs.in-project true

9. Restore settings

Syncalicious

from /Users/ve/Library/Mobile Documents/com~apple~CloudDocs/Syncalicious/macbook-air-andrey.local to ~/Library/Preferences

10. Add defaults

chflags nohidden ~/Library  # Show Library folder
defaults write com.apple.finder AppleShowAllFiles true  # Show hidden files
defaults write com.apple.finder ShowPathbar -bool true  # Show path bar
defaults write com.apple.finder ShowStatusBar -bool true  # Show status bar

Enable key-repeating:

defaults write com.microsoft.VSCode ApplePressAndHoldEnabled -bool false              # For VS Code
defaults write com.microsoft.VSCodeInsiders ApplePressAndHoldEnabled -bool false      # For VS Code Insider
defaults write com.vscodium ApplePressAndHoldEnabled -bool false                      # For VS Codium
defaults write com.microsoft.VSCodeExploration ApplePressAndHoldEnabled -bool false   # For VS Codium Exploration users
defaults delete -g ApplePressAndHoldEnabled                                           # If necessary, reset global default

Fix controller Home button:

defaults write com.apple.GameController bluetoothPrefsMenuLongPressAction -integer 0
defaults write com.apple.GameController bluetoothPrefsShareLongPressSystemGestureMode -integer -1

killall Dock

Add separator to Dock:

defaults write com.apple.dock persistent-apps -array-add '{"tile-type"="small-spacer-tile";}'; killall Dock

11. Setup Go

go install mvdan.cc/gofumpt@latest
go install -v github.com/incu6us/goimports-reviser/v3@latest
go install github.com/segmentio/golines@latest
go install github.com/go-delve/delve/cmd/dlv@latest

go install google.golang.org/protobuf/cmd/protoc-gen-go@latest
go install google.golang.org/grpc/cmd/protoc-gen-go-grpc@latest

12. Setup VSCode

Install extensions:

./vscode-extension-install.sh

To create a list of installed extensions:

code --list-extensions > extensions.txt

dotfiles's People

Contributors

ivnvxd avatar

Stargazers

 avatar

Watchers

 avatar

Forkers

vmview

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.