Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add default path for programs and help #152

Closed
wants to merge 1 commit into from

Conversation

JakobDev
Copy link
Contributor

I just added default paths. Programmers can place their programs and help files inside the path and it can be run from everywhere. I know, you can create a file in /startup to set the Path, but I thinks this is a little bit overkill. Default paths are the better way in my opinion.

@SquidDev SquidDev added enhancement An extension of a feature or a new feature. feedback wanted Tell me what you want, what you really really want. labels Mar 20, 2019
@SquidDev
Copy link
Member

It'd definitely be nice to have an actual standard for where to place user programs, but it's definitely something I'd want to get a lot of feedback from the community on first.

Might also be better to put the user-controllable path before the /rom one, as it allows people to override built-in programs.

@kepler155c
Copy link

I like the idea, but there are a few concerns. People would not know intuitively to place files in these directories as these directories do not exist. Also, there is no default path for requires - this is a big one as there's no intuitive way to add require paths.

@Lupus590
Copy link
Contributor

@kepler155c startup files/directories don't exist by default either

@SquidDev
Copy link
Member

SquidDev commented Mar 20, 2019

Having had another think about this, and chatting with some folks on Discord, I'm actually less sure about this:

The nice thing about the current system is that every program can be self-contained. For instance, mbs installs everything into one folder. This means that uninstalling it effectively boils down to removing the .mbs folder.

This is somewhat close to what package managers like nix do - every package, library, etc.. gets its own install directory and the interesting ones are added to your PATH. Given that you can have multiple startup programs now, it'd definitely be possible to use this sort of approach instead.

I don't know, I'm just rather spitballing here, so if anyone else has comments, please do say.

@Lupus590
Copy link
Contributor

Would a way to add a program to the path without creating a startup file be better? Perhaps via a setting?

Say I downloaded and ran an installer for Hive (if I ever complete it) and it created /hive (and deployed Hive there) and edited the path setting to include /hive/hive.lua on the path.

@JakobDev
Copy link
Contributor Author

We can add a setting this too, but I think we need a specific folder. Many Programs are just one file, so they can be placed in this folder. It is good for newbies.

@Lupus590
Copy link
Contributor

Setting with a default value which makes /programs work?

@CrazedProgrammer
Copy link
Contributor

It feels kind of arbitrary, considering no existing package manager puts executables there. I like where this is going (FHS but for CC), but I think it needs a bit more thought put into it.

@Lupus590 Lupus590 mentioned this pull request May 14, 2019
@SquidDev SquidDev added the area-CraftOS This affects CraftOS, or any other Lua portions of the mod. label Jun 5, 2019
@SquidDev SquidDev closed this Jun 16, 2020
@JakobDev JakobDev deleted the newpath branch June 16, 2020 18:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-CraftOS This affects CraftOS, or any other Lua portions of the mod. enhancement An extension of a feature or a new feature. feedback wanted Tell me what you want, what you really really want.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants