Code Monkey home page Code Monkey logo

dotfiles's Introduction

Dotfiles for WebDevBox

This dotfiles repo was made to be used in my Distrobox image "WebDevBox".

You should fork this to make your own changes. Once you do, install Chezmoi is you're not using my WebDevBox and initialize it like this:

$ chezmoi init <git@your dotfiles fork url>

It will prompt you for information that will be saved in this local file:

$ cat ~/.config/chezmoi/chezmoi.toml

All the pulled templates will be here:

$ ls ~/.local/share/chezmoi

The idea is that it will use the template dot_zshrc.tmpl, for example, merge with the data in chezmoi.toml and generate your ~/.zshrc.

Now, just remember to always edit your dotfiles templates. Chezmoi give you some helpers:

$ chezmoi cd # will cd you to the dotfiles repo directory
$ chezmoi edit ~/.zshrc # will open the template in your editor

If you create new dotfiles, let's say you started to use Fish, then don't forget to add it to Chezmoi like this:

$ chezmoi add --autotemplate ~/.fishrc

If you have confidential information that would be bad to show up in your GitHub repository, make sure you first added it to the data file, something like this:

[data.user.google]
password = something-something

Then, when you add the file with autotemplate, the template will do its magic and this is what will end up in the repo:

export GOOGLE_PASSWORD={{ .user.google.password }}

You can check your data with:

$ chezmoi data

Whenever you change the template or the data file, just update everything:

$ chezmoi update

And then push the changes to your repo:

$ chezmoi cd
$ git add .
$ git commit -m "Update dotfiles"
$ git push

This should make for a much sane way to manage your dotfiles.

dotfiles's People

Contributors

akitaonrails avatar inovaprog avatar

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.