Commit Graph

187 Commits

Author SHA1 Message Date
Hedy Li c362feacaa
WeeChat: Update config
- Date stuff
- Quit msg
- colors
- nick/msg buffer styling :D

idk
2022-02-04 18:25:00 +08:00
Hedy Li 618c85881c
nvim: Add nvim 0.6 support
- It only warned me of vim.lsp.diagnostic renamed to vim.diagnostic so I
  only changed that.
- *Should* still work for nvim 0.5
2022-02-04 18:21:35 +08:00
Hedy Li 170857653a
Fish: Better looking prompt
- Prompt char being '>' instead of '$'
  Yes, just for the sake of having a little `~>` in my homedir :D
- Different color for the base dir in the prompt pwd section
- Right prompt of user@hostname and time

I've had this prompt for like MONTHS and this was sitting in my
uncommitted changes since then, lol.
2022-02-04 17:51:49 +08:00
Hedy Li c83bb33754
nvim: Add ',' as alternative leader key 2022-02-04 17:14:38 +08:00
Hedy Li 858f8b47c5
Tmux: Add tmux-resurrect plugin 2021-10-13 20:40:21 +08:00
Hedy Li a84da9d4a0
Vim: Add setting termguicolors 2021-10-09 13:05:29 +00:00
Hedy Li 1e7f2b137e
Emacs: move early-init to init and modify init file
Again, making vimL my primary dotfile lang by reducing elisp file lines
and number of files ;P
2021-10-02 20:53:32 +08:00
Hedy Li ac6a1c3b8c
Emacs setup script: Fix typo in chemacs directory listing 2021-10-01 05:28:06 +00:00
Hedy Li a29fea5cfb
Aerc setup script: Fix typo in error message 2021-10-01 05:11:28 +00:00
Hedy Li 81037d7978
Shell/scripts: Use .addpath_local and add .startup.sh
- Remove bin in .addpath because ~/bin is always at the top, and it will
  automatically get added in parse_addpath

- Put parsing of .addpath_local in parse_addpath instead of in fish
  setup script so that it can be shared in .startup.sh

- Add .startup.sh for init code for non-fish (but ideally posix like)
  shell.
2021-10-01 12:19:54 +08:00
Hedy Li 938877a70d
Switch to MIT license
I care about the configuration and scripts a tiny bit more now (I mean,
more commits and code since like several months ago). And I *do* care
(sort of) if people copy my config or scripts as-is without any
reference. Wait, do I? We're in the FOSS zone right?

Oh well who cares copilot doesn't even acknowledge the license AFAIK
lmao, but still, MIT is a little friendlier than WTFPL
2021-09-30 21:01:34 +08:00
Hedy Li 0f73c62356
Emacs setup script: Use ssh when cloning
One should go over and modify the script themselves if they want to use
my stuff anyway. And if it was me using it I would 99.99% of the time
have ssh stuff setup so this should be fine.
2021-09-30 20:54:30 +08:00
Hedy Li 8a38366ac9
Emacs setup script: Modify colors and messages 2021-09-30 20:53:49 +08:00
Hedy Li 5fc18f5433
Emacs setup script: Refactor, check version, add colors
- Check for emacs version before installing doom
- Check if emacs is installed before anything
- Add colors and boldness to errors and prompts
- Fixup indentation
- Fix invokation of doom at the end
- Consistency of output/messages

The way I did the colors was really messy and repetitive. I'm not sure
of the best solution for this yet. See, I want my scripts to be
standalone, which means they can be ran by themselves in a separate
environment so they shoudn't depend upon one another. Maybe I should
have like a dotscripts/lib/ansi to declare the color and text style
functions? idk
2021-09-30 12:06:25 +00:00
Hedy Li 0602d4d921
aerc: Use ~/.config/aerc/styles as stylesets dir
I couldn't use ~/local/aerc/stylesets because the outer aerc dir may act
as a symlink (see the setup script).
2021-09-29 18:03:33 +08:00
Hedy Li 9123786773
emacs/doom: Refactor and simplify config files
Part of my effort to make vimL the primary lang for my dotfiles
(currently it's still elisp, ugh)
2021-09-29 15:26:58 +08:00
Hedy Li c8fa05b31a
nvim: Use { 'for': 'filetype' } for filetype plugins
Even though I know that some of them only loads upon ftplugin so this is
kinda useless.
2021-09-29 06:56:43 +00:00
Hedy Li 218476c70a
nvim: Only plug coc if we have node
The 'node not found' error is annoying even though it only flashes for
<1s
2021-09-29 06:56:41 +00:00
Hedy Li 953ca7c35d
ssh: Use ~/ instead of /home/hedy in ssh config
Got 'no such file or directory' when using ssh on breadpunk.club because
my username wasn't hedy, LOL.

Guess it's also part of my effort to make my dotfiles able to be used by
others (fully) :)
2021-09-29 06:56:39 +00:00
Hedy Li aa39fcc99e
aerc: Add custom stylesheet
It's the same as default but with just the top bar colored for now
2021-09-29 06:56:37 +00:00
Hedy Li a371e4acb3
weechat: Don't enable mouse by default
I don't use it that often (I have /go and alt-g) and I need to use my
mouse for copying text.
2021-09-29 06:56:35 +00:00
Hedy Li c4ba157b84
aliases: Rearrange aliases 2021-09-29 06:56:34 +00:00
Hedy Li abc7ef1e23
aliases: Add aliases for syncing ~/local/usr/*
See previous commit for more info
2021-09-29 06:56:32 +00:00
Hedy Li b068d6aec8
envs: Add LD_LIBRARY_PATH and PKG_CONFIG_PATH
I use ~/local for compiling packages without root. It emulates
/usr/local, basically. So sometimes it might have .pc files etc in
corresponding pkgconfig/ in there or .so files in corresponding lib/.

I do this because I almost always don't have root, because I work on
tildes primarily (tilde.cafe to be specific) so yeah. If a package is
written in go or similar where building would be easy, the basic
workflow is this:

    cd ~/local/src
    git clone git@example.com:user/repo
    cd repo
    make PREFIX="$HOME/local" install

If all goes well the binary would be available at ~/local/bin.

For apt packages there is a higher chance of build failing and most of
them need other dependencies (plus some other historical reasons idk) so
I don't use ~/local/src[1], here's the general workflow:

    cd ~/Downloads
    apt source pkgname
    cd pkgname
    ls -A
    less INSTALL
    ./configure --prefix=~/local
    make PREFIX=~/local
    make install PREFIX=~/local

And most likely it would complain about some package not found in the
configure step, in which case I woukd repeat the steps for that package.

Eventually (if I hadn't given up yet), the binary would be sitting in
~/local/bin nicely.

Sometimes the package needs a lot of dependencies, in that case it may
take up a shit ton of disk space, so I would pack it in a .tar.gz so it
can be saved for future use.

For meson projects:

    cd ~/local/src
    git clone git@example.com:user/repo
    ls -A
    meson setup build
    meson compile -C build
    meson install -C build --destdir ~/local
    rsync ~/local/usr/local/ ~/local/ -avr
    rsync ~/local/usr/ ~/local/ -avr && rm -rf ~/local/usr

I don't use meson often so I'm unaware of a way to easily specify
PREFIX, if any.

So that's my life of getting stuff installed without root. Thanks for
coming to my ted talk. One day I'll probably copy this entire commit msg
and make it into a blog post.
2021-09-29 06:56:15 +00:00
Hedy Li 25a8ad7b7c
git: Tabs to spaces in .gitconfig
I've modified my vim settings to always use spaces (except go or
probably makefiles) since I've last touched my git config.
2021-09-29 06:56:10 +00:00
Hedy Li f2d9357ea3
git: Add 'pall' alias for pushall current branch
Same as pushall alias but omits the --all so only the current branch is
pushed. I sometimes find this useful when I have a development branch
that isn't ready yet and only want to push the primary branch to all
remotes.
2021-09-29 06:56:06 +00:00
Hedy Li 8f514dd679
Squashing commits to fix history ugh
nvim: Setup script install plug only if isn't installed

Part of my effort to make the scripts able to be run >once

--

README: Installation stuff and modify ToC

--

nvim: Add markdown ToC plugin

--

git: Config file tabs to spaces

--

aerc: Use ~/local/share/aerc and add setup script
2021-09-29 06:53:06 +00:00
Hedy Li dac2b6d154
shell: I finally gave in and aliased g to git
many many people do this. I didn't do it before because I haven't
bothered to, and I didn't think 3-chara git is THAT much... But today I
was working with yadm (aliased to y) and then immediately switched to
git and undoubtedly 3-chars and 1-char is a huge difference

In any case, I don't think there are much (if not, any at all) cli
scripts with 1 letter names. I can't remember but I'm pretty sure that's
against the 'poetry of cli naming' article :P
2021-09-29 06:45:36 +00:00
Hedy Li d4c94326c9
nvim: add vimagit and refactor plugin declarations 2021-09-29 06:45:35 +00:00
Hedy Li c8f43bd73f
tmux: set vi mode-keys 2021-09-29 06:45:34 +00:00
Hedy Li 7ea972ab73
fish: direnv hook 2021-09-20 11:40:58 +08:00
Hedy Li f649b7ae3f
nvim: fix conflicts 2021-09-20 11:40:25 +08:00
Hedy Li 0d8ac7c97a
nvim: add slope syntax plugin 2021-09-19 12:30:53 +00:00
Hedy Li ff56900516
fix typo in aerc 2021-09-09 07:17:18 +00:00
Hedy Li ba3c915bab
nvim: fix scdoc detect and add a new plugin 2021-09-07 18:09:02 +08:00
Hedy Li 0a334f60de
git: set default branch to main because why not 2021-09-07 17:54:09 +08:00
Hedy Li aa0034494c
nvim: add vim-toml 2021-08-30 13:29:32 +08:00
Hedy Li 46044bfc84
fix complete lua reference and remove endwise 2021-08-29 21:10:00 +08:00
Hedy Li fa252e187b
nvim: rename autocomplete.lua -> complete.lua because I have autopairs 2021-08-25 13:34:33 +08:00
Hedy Li 1d7831e137
nvim: remove vim.o.completeopt in autocomplete.lua 2021-08-25 13:32:03 +08:00
Hedy Li ba50cfffee
nvim: add completeopts 2021-08-24 11:49:10 +08:00
Hedy Li 9ebb8a9a9a
scripts: reformat dotscripts/setup/emacs 2021-08-24 11:48:36 +08:00
Hedy Li b4457d1983
reformat readme 2021-08-24 11:43:29 +08:00
Hedy Li 8e5075d798
Merge branch 'master' of git.sr.ht:~hedy/dotfiles 2021-08-23 08:47:06 +00:00
Hedy Li 6ff11c6ae2
bin/mvtmp: use --verbose for mv 2021-08-23 08:46:41 +00:00
Hedy Li e98fd72ee3
nvim: remove obsolete comment in general.vim 2021-08-23 13:17:39 +08:00
Hedy Li 485a417701
vim: switch auto-pairing plugin 2021-08-23 10:03:44 +08:00
Hedy Li f279cff8be
nvim: add some comments in autocomplete.lua and plugins.vim for <CR> 2021-08-22 17:54:40 +08:00
Hedy Li 72048a8197
nvim: add nvim-compe mappings for C-Space, CR, C-f, C-d 2021-08-22 17:39:19 +08:00
Hedy Li 7e01cc44a9
update readme todo 2021-08-22 17:38:05 +08:00