anishathalye / dotbot

A tool that bootstraps your dotfiles ⚡️

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Dotbot should be able to automatically update any and all files I have being tracked

davidawad opened this issue · comments

maybe I'm not understanding this, but shouldn't it be obvious to have a ./install update or something that looks through all the files I'm symlinking and prepares a commit for me?

it would be a lot better than having to manually add each dotfile into install.conf.yaml and then add all of them to git as well.

I'm not sure I fully understand... What exactly do you imagine the workflow should be like?

sorry about the lack of clarity. so let's say I copy a bunch of stuff into the dotfiles repo. I'd love it if it could make some default assumptions. e.g. ~/.something: something for all the files that are in the repo to make migrating to dotbot a little less manual

that way I could say, "dotbot, there are some new files I want you to track in git for me, look through your config and make sure it has everything that's in this folder, if not add it"

then dotbot might look, notice all the files that are new, and then add them to it's own config.

from there you just git add/commit etc.

For migrating to Dotbot, there's this tool: https://github.com/Vaelatern/init-dotfiles

I think @davidawad wants a feature that can add new files to an existing Dotbot-powered dotfiles repo.

For instance, I hear about i3, and I want to give it a try.

If I install it, I create the file ~/.config/i3/config to customize my new window manager. Once I'm happy with it, I want to track it:

$ cd ~/.dotfiles
$ mkdir i3
$ mv ~/.config/i3/config i3/
$ vim install.conf.yaml # add `- ~/.config/i3/config: i3/config`
$ ./install
$ # if something wrong – like `- ~/.config/i3/config: i3/confif` –, fix and repeat

These steps can be automated, and, FWIU, Vaelatern/init-dotfiles only manages a set of files and – as its name suggest it – initialize a new dotfiles repo.

Hmm, okay.

I'm not sure if implementing this feature saves that much work, though. And I don't think it's easy to implement (sometimes people have pretty complicated install.conf.yaml files).

I implemented this as a Git hook.

https://github.com/gwerbin/dotbot-autobot

Oh that's pretty cool! Wanna add a note about it to the wiki?

as it turns out I'm a terrible communicator lol.

So yes I'd like it if I only ever had to add the file to my .dotfiles folder and commit it.

I should never have to add it manually to the yaml or run ./install everytime.
That's just me though. Im definitely gonna try out @gwerbin's solution

@davidawad Does this kind of globbing support your initial request? #142

For example:

# set defaults use_globs: true
link:
  ~/: dotfiles/*

added dotbot-autobot to wiki.