No package manager¶
Pastacode intentionally does not include a package manager. There are several reasons:
External packages are outside your control. You may be relying on workaround, but the external package may suddenly change so it no longer works.
Using packages from the internet is dangerous, there have been multiple instances of malicious code being included that way.
Sometimes packages online are not allowed to be used, which could land your company in legal trouble.
Self-written code is often better, it does exactly what you need, and follows all the internal procedures.
Why would you want to share your code? You invested a lot of resources in it!
Adding a dependency¶
If you want to share code anyway, for example code made within your company, this is easy:
Simply copy the code you need into a subdirectory, which is conventionally called
0dependencies (with a zero).
If you have multiple dependencies, each can have its own directory without
This way you are in full control over any changes made to the code, preventing unexpected bugs, exploits and licensing problems!
Using your code in your other projects¶
The only thing you need to do for your colleagues to use your code, is give them access to it.
They can then copy it to
0dependencies. This can also be done with
git submodule add ....
Despite the warnings at the start of this page, there are some pieces of code that are a lot of work to write, and would be nice to share.
You can of course use the way described above, but often it is even easier - the code might already be included in Pasta, or might be added soon.
Pastacode intends to be ‘batteries included’, so any useful code is included in its standard library, to make it available to everyone without any extra steps.