- Notifications
You must be signed in to change notification settings - Fork0
License
Apache-2.0, MIT licenses found
Licenses found
thi8v/devspace
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
Warning
THIS PROJECT IS WORK IN PROGRESS! USE THIS PROGRAM AT YOUR RISK, FOR NOW ITSBEHAVIOR ISN'T REALLY LOGIC.
devspace helps you to quickly start all the programs you need to dev, like runtmux
split the window vertically then horizontally, open programs inside yourpanes etc ..
Cargo and Rust1.85.0
.
- Clone the repo,
$ git clone git@github.com:thi8v/devspace.git
- Move into it,
$ cd devspace
- Install it locally through cargo,
$ cargo install --path .
- Use it
$ devspace ...
if it doesn't work make sure the directory wherecargo puts the Rust binaries is in yourPATH
environment variable.
$ cargo install devspace
Devspace uses the filesystem to store some stuff and has one directory.This directory contains the following:
config.ron
: the configuration of devspace, the Trees and the default Treedb.ron
: the Space with their working directory and their Tree.
The directory is evaluated based on the following priorities:
- the
--dir <path>
argument. - the
DEVSPACE_DIR
global variable. - and fallbacks to the default
$HOME/.devspace/
.
Space: its a directory and more data, stored in the database, usualy thedirectory of a project and its tree.
Tree: the programs and its hierarchy that are run when launching a Space.It's a Tree composed of things likeTmuxVSplit(..)
,TmuxHSplit(..)
,Cmd(..)
, etc.. see more below.
To create a new Space for the current directory,
$ devspace init
Or to create a new Space for a specific directory
$ devspace init /path/to/my/veryspecific/directory
You can print the list of spaces stored,
$ devspace list-spaces
To remove a Space, use theremove
subcommand with the Space name,
$ devspace remove SPACE_NAME_HERE
And the most useful command from all of them,go
!
$ devspace go SPACE_NAME_HERE
it will launch your Space with its configured Tree.
.. or just type
$ devspace --help
to get some help and discover sub commands, arguments flags etc..
Warning
PLEASE NOTE THAT THIS PROJECT IS WORK IN PROGRESS BUT THIS PART IS EVEN MOREIN PROGRESS, EXPECT BUGS AND NON-LOGIC BUG / BEHAVIOR OF THIS PROGRAM.
This Tree will run the specified command in the shell. The command hasplaceholders, in the Command String you can put{ .. }
and between thebrackets you can put variable names that will be replaced when launched.
Support variable names in placeholders:Space.wdir
: replaced with the Space's working directory path when launchedThat's it actually lmao
Cmd(COMMAND_STRING)
This tree will make a Vertical split in the Tmux session, with one the left(lhs) its own tree, and same on the right (rhs).
TmuxVSplit(rhs:ANOTHER_TREE,// optionallhs:ANOTHER_TREE,// optional)
This tree will make an Horizontal split in the Tmux session, with one the left(lhs) its own tree, and same on the right (rhs).
TmuxVSplit(rhs:ANOTHER_TREE,// optionallhs:ANOTHER_TREE,// optional)
Here is a (working lmao) example of a tree,
TmuxVSplit(lhs:Cmd("clear && hx "),rhs:TmuxHSplit(),)
Licensed under either of
- Apache License, Version 2.0 (LICENSE-APACHE orhttp://www.apache.org/licenses/LICENSE-2.0)
- MIT license (LICENSE-MIT orhttp://opensource.org/licenses/MIT)
at your option.
Feel free to contribute. For the moment there is no documentation but it will come.
Unless you explicitly state otherwise, any contribution intentionally submittedfor inclusion in the work by you shall be dual licensed as above, without anyadditional terms or conditions.