-
-
Notifications
You must be signed in to change notification settings - Fork 251
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
File System Access API #1594
base: master
Are you sure you want to change the base?
File System Access API #1594
Conversation
Writing to a file is being fixed as I noticed it was erasing the data and not writing. |
Also, tons of bug squashing and quality improvement will probably come in last. ToDo list for that time:
|
#81 Need to consider this issue. Could probably implement this as a |
Another thing to do: Edit: Not needed. Just let the people making the projects do it. |
It seems as though the files can be read and written to, but after they are written to, the extension breaks. Here's a modified working version of the code that is able to save data to the file more than once without breaking: |
Oop, forgot to format before committing, oh well. |
Okay, I now have reading and writing singular files done! |
And thank you, @kindpump for the fixes! That genuinely helped a ton and prevented my terrible, garbled JavaScript from breaking everything. |
If he's helped significantly, you can ask him if he wants to be credited for the help. |
I have put direct links to all resources and contributions in lines 7 to 16. |
I may go ahead and push some improved attribution |
Ah, named it wrong, oh well. |
4 main features left to implement before refining.
|
Kate seems to not be committing changes |
Rewriting to match what my original goals were: Create a functional one.
apparently giving it my email just shows it without the numbers.. huh.. enjoy ig. |
I just realized why my commits aren't under my username, and it is stupid. Should be fixed next commit. |
Pushing changes to files doesnt work for |
I am no longer working on the second rewrite. I'm on to a third and final rewrite. I will not be revisiting that version. Edit: Why specifically executable files? |
I'm making a game that i will package as an exe |
The rewrite should fix it by allowing the end user (people like you or me) to interact with the raw functions of the API (plus a few needed tools). I can't say it is definite though. |
Oops, I forgot about this. Luckily I still have the repo on a hard drive, I'll get to work on it during class tomorrow I guess. |
still working on it? |
I should work on it, I have done a good bit and don't particularly want it to go to waste. Thanks for reminding me. |
Rereading the W3C draft, looks like I overlooked a couple of things about querying and requesting permissions |
That shouldn't happen... 2024-12-24.14-00-58.mp4 |
This is a cool extension, I am just wondering if this would warrent a new API like |
The browser should already handle that. You'll be prompted to allow or deny access to edit the file. I guess it'll be determined when I'm done. If the browser handles it, then there shouldn't be a reason to proceed with a new API. If it doesn't, then a new API might be required. |
The browser does handle it, but it also handles all the other notable "dangerous" API's like geolocation and stuff. TurboWarp has a security manager which ALSO handles it all including but not limited to downloading, fetching, geolocation, and more. |
In that case, it probably will need one. |
just my opinion, but IMO the blocks don't really need to just be direct javascript code as their names. that's not very scratch-like (and probably unintuitive too) |
I could make the javascript part included, but not as a main part of the extension. Maybe hidden behind a button, though (like "Advanced Blocks" or something). I'll keep working on the javascript part, as the main part could just reference the existing stuff. |
Notice: The extension is receiving a well needed rewrite! Why? BUGS!
Contribution of ideas, images, code, etc. is welcome, plus you will be
recognized in the JS for your contribution (even if it doesn't make it through).
License:
GNU-GPL-v3*
Description
This extension brings the File System Access API (not to be confused with File System API) to Turbowarp.
Use cases
Features
Entire File System Access API
What else would you think it was?
If there is something in the JS file that needs to be changed, please let me know.