diff --git a/docs/document/Articles/docs/Neovim.md b/docs/document/Articles/docs/Neovim.md deleted file mode 100644 index b4bdaf2..0000000 --- a/docs/document/Articles/docs/Neovim.md +++ /dev/null @@ -1,76 +0,0 @@ -# - -## Install plugin manager - `lazy.nvim` - -```bash -nano ~/.config/nvim/lua/sharpchen/lazy.lua -``` - -```lua -local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim" -if not vim.loop.fs_stat(lazypath) then - vim.fn.system({ - "git", - "clone", - "--filter=blob:none", - "https://github.com/folke/lazy.nvim.git", - "--branch=stable", -- latest stable release - lazypath, - }) -end -vim.opt.rtp:prepend(lazypath) - -require("lazy").setup({}) -``` - -```lua --- ~/.config/nvim/init.lua - -require("sharpchen") -require("sharpchen.lazy") // [!code ++] -``` - -## Organize plugins - -For plugins need options, store them in none-index file separately. - -```lua --- ~/.config/nvim/lua/sharpchen/plugins/colorscheme.lua -return { - -- ... all colorscheme -} -``` - -For plugins without options, store them in `./init.lua` - -```lua --- ~/.config/nvim/lua/sharpchen/plugins/init.lua -return { - -- ... -} -``` - -To import plugins - -```bash -nano ~/.config/nvim/lua/sharpchen/lazy.lua -``` - -```lua --- ~/.config/nvim/lua/sharpchen/lazy.lua - -local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim" -if not vim.loop.fs_stat(lazypath) then - vim.fn.system({ - "git", - "clone", - "--filter=blob:none", - "https://github.com/folke/lazy.nvim.git", - "--branch=stable", -- latest stable release - lazypath, - }) -end -vim.opt.rtp:prepend(lazypath) - -require("lazy").setup("sharpchen.plugins") // [!code ++] -``` diff --git a/docs/document/Articles/docs/Setup nix-on-droid.md b/docs/document/Articles/docs/Setup nix-on-droid.md index b316235..470046f 100644 --- a/docs/document/Articles/docs/Setup nix-on-droid.md +++ b/docs/document/Articles/docs/Setup nix-on-droid.md @@ -23,14 +23,13 @@ > [!NOTE] > You can wrap the same as bash function by `awk` or other text manipulation tools. - ## Init - nix-on-droid may ask for url for certain file, if the url is not accessible on your phone, download it and transfer to your phone. And replace the default url as `file:///sdcard/...` - type `yes` when nix prompt for downloads for first init. - add and update channels: ```sh - nix-channel --add https://github.com/nix-community/home-manager/archive/release-24.05.tar.gz home-manager && channel + nix-channel --add https://github.com/nix-community/home-manager/archive/release-24.05.tar.gz home-manager && nix-channel --update ``` > [!TIP] > If you use the wrapper function mentioned above, would be like this: @@ -67,14 +66,14 @@ mkdir -p ~/.ssh/ && touch ~/.ssh/authorized_keys && echo >> ~/.ssh/authori - start ssh daemon by `sshd` ```sh -sshd -p -h -d +$(which sshd) -p -h -d ``` `-d` is essential to know whether your port is been taken or not. See details in `man sshd`. - now connect to nix-on-droid from your computer -```ps1 +```sh ssh -l nix-on-droid -p ```