Git Product home page Git Product logo

dotfiles's Introduction

dotfiles

Config files for my *NIX systems.

Other Configuration

There are some other configuration steps that must be taken manually, depending on the platform.

Remapping <->

To switch <ESC> and <CAPS-LOCK>, the method depends on the platform:

  • Linux-based (GNOME): install gnome-tweaks (sudo apt install gnomre-tweaks) and use the menu, it's an option in there.
  • MacOS: Use karabiner, install it through brew + the provided dotfiles.

Usage

For now the configuration files are managed using GNU Stow

To use stow, first install it with the distro's package manager:

sudo apt install stow

Then to "install" each configuration, simply run:

stow <app>

Application Specific Instructions

Environment

This contains some general settings for the environment that I want shared across systems. Note that this assumes that the system is *NIX (i.e: Linux, macOS or WSL).

This contains a .system-env.sh file with some environment variables that are used to configure some of the basic tools that are assumed to be installed as part of the base installation (meaning, tools that I always want to be there, some of them may not be in some systems by default and require some installation).

The environment loaders should also be configured to automatically load a .system-env-specific.sh file which contains system specific configurations, which could also contain overrides to shared configurations.

zsh

Setting up the zsh shell depends on the platform.

Installation

On MacOS it should be the default, so you can skip this section.

To setup the zsh shell, you first need to install it. It should be in all the package managers:

sudo apt install zsh

Setup

The setup is mostly done using Oh My Zsh.

The setup is done through a provided remote script:

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

Neovim

For my current uses of Neovim, it's better to use the latest version possible. For that we either need a package manager that supports following HEAD or manually manage it through the repository.

The simplest version is to use Homebrew, which supports this kind of use out of the box:

brew install neovim --HEAD

Else, we need some manual steps:

First download the neovim source code from the git repository:

git clone https://github.com/neovim/neovim

Create a target folder for the local installation. By default I use ~/neovim as the target.

mkdir ~/neovim

The next step is actually building the source. First you need to make sure to install the build requirements. They are described here, but for Debian based systems (Debian, Ubuntu, PopOS, etc.):

sudo apt-get install ninja-build gettext libtool libtool-bin autoconf automake cmake g++ pkg-config unzip curl doxygen

Now, setup the target for installation and start building (for more information, see this):

make CMAKE_EXTRA_FLAGS="-DCMAKE_INSTALL_PREFIX=$HOME/neovim"  CMAKE_BUILD_TYPE=Release -j4
make install

And now, the nvim binary is created at: ~/neovim/bin/nvim. You need to make sure it's available in the PATH. For this, you can either add this path directly to it, or more cleanly add a symlink to a more standard bin directory:

ln -s ~/neovim/bin/nvim ~/.local/bin/nvim

Now we have the binary ready to be used. However, the current state of the configuration makes it so that neovim is not really usable without some extra steps.

Post Installation

After the installation of the nvim binary, you need to install the Plug plugin manager and install the right plugins for it to work correctly.

Plug.vim This is the package manager. This is the main applications that we need to install manually, and then this will handle the rest.

To install it, just download the source and put it in the autoload folder:

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

Plugins Once Plug.vim is set up, just run :PlugInstall inside a nvim instance and everything should be mostly setup:

nvim -c PlugInstall

There are still a couple of extra additions that are nice to have:

Python3 Configuration

TODO

fzy-lua-native Installation

This is C FFI extension for the lua implementation fzy algorithm for faster searching (used by Telescope) which speeds up the fuzzy searching.

To install this:

git clone https://github.com/romgrk/fzy-lua-native
cd fzy-lua-native
make

This will create a compiled binary on static/<output> (output depends on the platform). You can now install it by copying it to /usr/local/lib:

sudo cp static/libfzy-linux-x86_64.so /usr/local/lib/
sudo ldconfig

And it should be ready to go (I have not checked yet though).

Pretty Icons for LSP

The pretty icons for the LSP are provided by the lspkind plugin. To show the icons, you need to install VSCode codeicon font and setup your shell to use that font for non-ASCI glyphs.

Tmux

To fully install tmux and tmuxinator, you need to install first the Tmux Plugin Manager (TPM). To do it, you just need to download the repository inside the ~/.tmux/plugins/tpm directory:

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

The rest is handled by the configuration. The first time you open tmux (and any time you install a new plugin), you need to actually run the installtion of the plugins. For that just run prefix + I. NOTE that this looks like it's doing nothing, but after a couple of seconds it should report something.

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.