Merge branch 'main' of https://github.com/DarthMooMancer/Polydev
This commit is contained in:
+2
-2
@@ -1,10 +1,10 @@
|
||||
### Lazyvim and Config
|
||||
```lua
|
||||
-- There is no need to copy this. This is an example and it consists of the defaults. This is a Java example.
|
||||
-- There is no need to copy this. This is an example and it consists of the defaults. This is a java example
|
||||
require {
|
||||
"DarthMooMancer/Polydev",
|
||||
config = function()
|
||||
require("Polydev").language.setup({
|
||||
require("Polydev").java.setup({
|
||||
project_root = "~/projects",
|
||||
keybinds = {
|
||||
["<Esc>"] = "CloseTerminal",
|
||||
|
||||
+2
-1
@@ -3,9 +3,10 @@
|
||||

|
||||
----
|
||||
### What is Polydev?
|
||||
Polydev is a simple plugin that gives neovim some nice functions while being extremely extensible for developers. Are there better plugins? Most likely, however this has simple functions for:
|
||||
Polydev is a simple plugin that gives neovim some nice functions while being extremely extensible for developers. It automatically detects your language and enables the module for that language. It is a standalone plugin that has no dependencies aside from getting file types. Below are a few features that are currently implemented:
|
||||
|
||||
* Creating New Projects
|
||||
* Creating New Files
|
||||
* Building Files
|
||||
* Running Files
|
||||
* Builtin Terminal
|
||||
|
||||
@@ -8,7 +8,10 @@
|
||||
require {
|
||||
"DarthMooMancer/Polydev",
|
||||
config = function()
|
||||
require("Polydev").language.setup()
|
||||
require("Polydev").setup()
|
||||
--require("Polydev").language.setup({
|
||||
-- configs
|
||||
--})
|
||||
end
|
||||
}
|
||||
```
|
||||
@@ -20,5 +23,8 @@ MiniDeps.add({
|
||||
source = 'DarthMooMancer/Polydev',
|
||||
})
|
||||
|
||||
require("Polydev").language.setup()
|
||||
require("Polydev").setup()
|
||||
--require("Polydev").language.setup({
|
||||
-- configs
|
||||
--})
|
||||
```
|
||||
|
||||
+4
-6
@@ -6,11 +6,9 @@
|
||||
require("Polydev").c.setup({
|
||||
keybinds = {
|
||||
["<Esc>"] = "CloseTerminal" -- Closes terminal, esc by default.
|
||||
["<leader>cb"] = "CBuild", -- Building all C Files in src directory in.
|
||||
["<leader>cr"] = "CRun", -- Runs <Project_name> in your build directory
|
||||
["<leader>cnf"] = "NewCFile", -- Creates a new c file in the current project src folder
|
||||
["<leader>cnp"] = "NewCHeaderFile", -- Creates a new header file in the current project src folder
|
||||
["<leader>cnh"] = "NewCProject", -- Creates a new project in the project directory in the config, defaults to ~/Projects/C unless project_root is set
|
||||
},
|
||||
["<leader>pb"] = "CBuild", -- Building all C Files in src directory in.
|
||||
["<leader>pr"] = "CRun", -- Runs <Project_name> in your build directory
|
||||
["<leader>nf"] = "NewCFile", -- Creates a new c file in the current project src folder
|
||||
["<leader>nh"] = "NewCHeaderFile", -- Creates a new header file in the current project src folder
|
||||
})
|
||||
```
|
||||
|
||||
@@ -3,11 +3,10 @@
|
||||
-- These are defaults, so no need to copy them
|
||||
require("Polydev").java.setup({
|
||||
keybinds = {
|
||||
["<leader>jb"] = "JavaBuild" -- Building all Java Files in src directory in.
|
||||
["<leader>jr"] = "JavaRun" -- Runs Main.java in the out folder in your project_root
|
||||
["<leader>jnf"] = "NewJavaFile" -- Creates a new Java file in the current project src folder
|
||||
["<leader>jnp"] = "NewJavaProject" -- Creates a new project in the project directory in the config, defaults to ~/Projects unless project_root is set
|
||||
["<Esc>"] = "CloseTerminal" -- Closes terminal, esc by default.
|
||||
["<Esc>"] = "CloseTerminal" -- Closes terminal, esc by default.
|
||||
["<leader>pb"] = "JavaBuild" -- Building all Java Files in src directory in.
|
||||
["<leader>pr"] = "JavaRun" -- Runs Main.java in the out folder in your project_root
|
||||
["<leader>nf"] = "NewJavaFile" -- Creates a new Java file in the current project src folder
|
||||
}
|
||||
})
|
||||
```
|
||||
|
||||
+13
-1
@@ -12,7 +12,19 @@ require("Polydev").language.setup({
|
||||
* It will automatically make the new Root Directory, so you don't have to worry about making it.
|
||||
|
||||
## Keybinds
|
||||
* Keybinds are different for each language, but each one can be changed. Look at the language you want to change for keybind documentation.
|
||||
* Every language has the same keybinds so it is easy to remember keybinds and not have to remember thousands of keybinds.
|
||||
* The only keybind that doesnt change no matter what happens is creating a new project. Enter the language you want, then enter the project name and boom! new project.
|
||||
```lua
|
||||
require("Polydev"}.language.setup({
|
||||
keybinds = [
|
||||
["<Esc>"] = "CloseTerminal",
|
||||
["<leader>pb"] = "languageBuild",
|
||||
["<leader>pr"] = "languageRun",
|
||||
["<leader>nf"] = "NewlanguageFile", -- such as .c files
|
||||
["<leader>nh"] = "Newlanguage_secondaryFile", -- such as .h files
|
||||
}
|
||||
})
|
||||
```
|
||||
|
||||
## Terminal
|
||||
* The terminal has a couple of options that can be customized and with more to come
|
||||
|
||||
Reference in New Issue
Block a user