🍻 Serve fruity dotfiles for brew fans! 🤩
DotPub makes mounting your dotfiles as easy as drinking:
NOTE: You need Python 3.9 or greater to run the script below.
# Find the DotPub.
git clone https://github.com/hellozhaowenkai/dotpub.git
# Into the DotPub.
cd dotpub
# Then order a cup of drink from the publican.
python publican.py order vim
# Or just have a taste of all drinks we served!
python publican.py order --all
NOTE: I'll regularly add new configurations so keep an eye on this repository as it grows and optimizes.
usage: publican.py [-h] [-v] ACTION ...
Serve fruity dotfiles for brew fans!
optional arguments:
-h, --help show this help message and exit
-v, --version show program's version number and exit
subcommands:
Chose the action you want to execute.
ACTION
brew manage the supported formulae via brew
menu list the supported formulae
order mount your formulae config files
cancel unmount your formulae config files
tab show the supported formulae status
usage: publican.py brew [-h] [-s] [-f] [--use-tuna-mirror] [--auto-update] [-a] COMMAND [FORMULAE ...]
Manage the supported formulae via brew.
positional arguments:
COMMAND command supported by brew
FORMULAE chose the formulae those you want to manage
optional arguments:
-h, --help show this help message and exit
-s, --simplify simplifies the output
-f, --force manage formulae without asking for confirm
--use-tuna-mirror use TUNA mirror for brew commonds
--auto-update run on auto-updates (e.g. before brew install) to skips some slower steps
-a, --all manage all of the formulae those be supported default
usage: publican.py menu [-h] [-s] [-a] [FORMULAE ...]
List the supported formulae.
positional arguments:
FORMULAE chose the formulae those you want to manage
optional arguments:
-h, --help show this help message and exit
-s, --simplify simplifies the output
-a, --all manage all of the formulae those be supported default
usage: publican.py order [-h] [-a] [FORMULAE ...]
Mount your formulae config files.
positional arguments:
FORMULAE chose the formulae those you want to manage
optional arguments:
-h, --help show this help message and exit
-a, --all manage all of the formulae those be supported default
usage: publican.py cancel [-h] [-a] [FORMULAE ...]
Unmount your formulae config files.
positional arguments:
FORMULAE chose the formulae those you want to manage
optional arguments:
-h, --help show this help message and exit
-a, --all manage all of the formulae those be supported default
usage: publican.py tab [-h] [-s] [-a] [FORMULAE ...]
Show the supported formulae status.
positional arguments:
FORMULAE chose the formulae those you want to manage
optional arguments:
-h, --help show this help message and exit
-s, --simplify simplifies the output
-a, --all manage all of the formulae those be supported default
Let's take Vim
as an example.
All Vim stuff are store in counter/vim/
folder:
formula-info.json
tell us where the config files should put to.- others such as
.vimrc
are all Vim's config files.
rm backups/vim/*
mv ~/.vimrc backups/vim/.vimrc
ln -s counter/vim/.vimrc ~/.vimrc
rm ~/.vimrc
mv backups/vim/.vimrc ~/.vimrc
rm backups/vim/*
The idea is inspired by:
The social preview is designed by:
- Canva: Collaborate & Create Amazing Graphic Design for Free
- Figma: The Collaborative Interface Design Tool
Thanks to all of them!
Thanks for taking the time to contribute! Please check out our Contributing Guidelines for ways to offer feedback and contribute.
Trying to report a possible security vulnerability? Please check out our Security Policy for guidelines about how to proceed.
This project and everyone participating in it is governed by the Contributor Covenant Code of Conduct.
Licensed under the GNU Affero General Public License, Version 3.0.
See LICENSE
and NOTICE
for complete details.