Diplo is a script runner and dependency manager made in rust mainly for Deno.
Documentation Tricked.pro/diplo
Installing
You can download diplo from the releases tab or install it using cargo install diplo ( Recommended way since it adds diplo to the path )
Windows
Theres a .msi installer for diplo in the windows.zip that you can use to install diplo make sure to select the add to path option
Theres also a .exe which you can use instead but this requires you to add it to your path manually
Linux
Theres a .deb file in the linux.tar.gz which you can use to install diplo on debian
Theres also a PKGBUILD for archlinux users
Theres also a binary in the linux.tar.gz which you can move into your bin folder
Mac
Theres a binary which you can move to your bin folder
After that you can run diplo init for a interactive setup.
or use diplo init -y for a one command setup
Features
File watching
Diplo can replace Denon in terms of restarting on file change.
To restart a script on save you just have to append --watch to diplo run <script>
Easy dependencies
Adding a new dependency is as simple as running diplo add natico or whatever else you need
Multiple dependencies at once are supported
$ diplo add natico
info: Successfully added natico@3.0.0-rc.1 to the dependencies
adding std modules
$ diplo add -s fs
info: Successfully added https://deno.land/std@0.110.0/fs/mod.ts to the dependencies

Script running
You can easily create scripts like you do with npm and yarn
if you want to run the script just do diplo run start to run the start script.
[]
= "deno run -A mod.ts"
= "node index.js"
Dependencies
Diplo will automatically create a deps.ts file in the .diplo folder if you have dependencies specified in the diplo.json file
[]
= "https://deno.land/x/natico/mod.ts"
= "https://deno.land/std@0.110.0/http/server.ts"
Updating Dependencies
updating dependencies is a as simple as running diplo update note this will only update deno.land/x/ packages
$ diplo update
info: updated discordeno to 12.0.1 from 11.0.1
info: updated harmony to v2.2.0 from v1.2.0
info: updated std to 0.110.0 from 0.10.0
info: updating done!
Import Map Support
Typescript users will have to add this to the vscode settings.json (.vscode/settings.json)
import * as server from 'server';
- note Diplo will automatically append
--import-map="./.diplo/import_map.jsonafterdeno run.
=true
Exports
Diplo can add custom exports to your dependencies
[]
= {="https://deno.land/x/natico@3.0.0/mod.ts", = "* as natico" }
= {="https://deno.land/x/doomfetch@1.0.0/mod.ts", = "default as doomfetch"
would end up being
export { default as doomfetch } from 'https://deno.land/x/doomfetch@1.0.0/mod.ts';
export * as natico from 'https://deno.land/x/natico@3.0.0/mod.ts';
Dotenv Support
Diplo can automatically add environment variables using the rust dotenv module instead of the deno based one
=true
Example Config
This is a example of a diplo config.
= "diplo project"
= false
= false
[]
= { ="https://deno.land/x/natico@3.0.0/mod.ts", = "* as natico" }
= "https://deno.land/std@0.112.0/fs/mod.ts"
= "https://deno.land/std@0.112.0/ws/mod.ts"
= "https://deno.land/x/discordeno@12.0.1/mod.ts"
[]
[]
= "ls -la"
Screenshots
Diplo running with watch option on

Diplo running without watch option

Updating modules

Adding modules

Donating
89prBkdG58KU15jv5LTbP3MgdJ2ikrcyu1vmdTKTGEVdhKRvbxgRN671jfFn3Uivk4Er1JXsc1xFZFbmFCGzVZNLPQeEwZc
0xc31a1A5dCd1a4704e81fB7c9C3fa858b9A00C7fb
License
This project is licensed under the terms of the Apache License 2.0
