Website v.0.2 update notes


Website v.0.2 update notes

V0.2

TLDR;

Explanation of this update:

This update ended up being a lot bigger than I thought it would originally be, this update mostly however added one thing, a basic version of the filesystem

The filesystem

The filesystem is fairly basic. It’s basically a variable that contains the current directory and apart from that a bunch of if statements. I think the problems with this are fairly obvious. There is no way to add folders to this system, the code is really really inefficient, and also the code is about 200 lines long, just the most basic if statements.

So anyway, how does it work:

Basically there is a variable that contains the current folder the user is in, then there is an array that is manually created for each folder that contains the folders and files inside that folder. Whenever a pwd or print working directory command is run there is an if statement for every case that that directory could be, and if it isn’t any of those it bugs out. Whenever a cd command is run, there is a separate if statement for each possible directory they could try to cd into for any possible folder. Then if an ls or list directories command is run it checks the current directory and then lists the contents of the array that is associated with that current directory. I will not go into why this is a terrible terrible system as I could be here for hours, but creating this system did teach me a lot so I think it was worth it.

Syncing my project to Github from my computer the smart way

Zade, one of the people who was giving me some help, called me a monster for the way I was pushing my files to github, and he had a point. Basically I would copy and paste the file contents to the file in github. This is stupid for so many reasons. So I fixed that, I did it the SLIGHTLY better way by downloading the github desktop app, bear in mind that I was using VS Codium so I could have just synced it through that but I have never been bothered.

What went wrong and how did I fix it:

Changes to the plan:

Not much, I just now realize it’s going to be a LOT harder than I first anticipated to get the filesystem done in an actually good way.