https://github.com/leonardsoncc/scrips.nvim
Help you to find, manage and run your scripts
https://github.com/leonardsoncc/scrips.nvim
lua neovim neovim-plugin
Last synced: 6 months ago
JSON representation
Help you to find, manage and run your scripts
- Host: GitHub
- URL: https://github.com/leonardsoncc/scrips.nvim
- Owner: LeonardsonCC
- Created: 2022-12-10T13:17:19.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2023-11-22T17:12:22.000Z (over 2 years ago)
- Last Synced: 2025-03-04T19:32:43.834Z (about 1 year ago)
- Topics: lua, neovim, neovim-plugin
- Language: Lua
- Homepage:
- Size: 32.2 KB
- Stars: 3
- Watchers: 2
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# scrips.nvim
Yep, this is just scrips without the `t`. I know, it's dumb.

## What this plugin can do for me?
At the moment, it'll help you to manage scripts.
- Create a folder to store scripts;
- Create scripts;
- Run the script file;
- Run selection;
- Telescope your script;
## Install
Using Packer
```lua
use {
"LeonardsonCC/scrips.nvim",
requires = "nvim-lua/plenary.nvim"
}
```
Setup plugin
```lua
require('scrips').setup()
```
Setup the Telescope extension
```lua
require('telescope').load_extension('scrips')
```
## Keymaps
You must set your own keymaps. This is what I personally use:
```lua
-- scrips
local scrips = require('scrips')
-- new script
vim.keymap.set('n', 'en', scrips.new_script, { noremap = true })
-- find scripts
vim.keymap.set('n', 'se', require('telescope').extensions.scrips.find_file, { noremap = true })
-- Run
vim.keymap.set('n', 'er', scrips.run_paragraph, { noremap = true })
vim.keymap.set('n', 'eR', scrips.run_file, { noremap = true })
```
## What I pretend to do
- [ ] Run selection
- [X] Folder to manage scripts in plugin
- [X] Telescope to find scripts managed by the plugin
- [ ] Better buffer names
- [X] Run the file based on his shebang e.g. `#! /bin/bash`
- [ ] Run the paragraph based on his shebang e.g. `#! /bin/bash`
- [X] Run paragraph
- [ ] Subfolders to help manage the scripts
- [X] Time elapsed
- [ ] Custom environment files