Skip to content
This repository was archived by the owner on Nov 30, 2025. It is now read-only.

Anonymous-cat1/Update-File

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Update File (Direct Access)

By Anonymous_cat1, co-written by GPT-4o-Mini.

A simple Turbowarp extension that uses the File System Access API to dynamically update files.

Security note

This allows any Turbowarp project unrestricted access any file you specify, which means it could modify, delete, or inject code into a file without your consent Never allow access to files that you care about to a project you're not familiar with.

Browser support

Your browser must support the File System Access API, you can find a support list here. Otherwise, the extension will not work.

Installation

To use this extension in Turbowarp (or in it's very plentiful mods), open Add Extension > Custom Extension and paste this link.

YOU MUST LOAD UNSANDBOXED. OTHERWISE IT WILL NOT IMPORT.

https://anonymous-cat1.github.io/Update-File/extension.js

How to use

To start, you can open a file with the Set File block. This should open your system's file picker.

Now, you can update a file with the Write content to file from [Format Dropdown] (Text) block.

Dropdown options:

  • Text

  • URI/URL (using a url will download whatever content the page has)

To read a file, use the Get content from file as [Format Dropdown] reporter.

Dropdown options:

  • Text

  • URI (always encoded as Base64)

  • Hex (returns an array of bytes)

To read a file's metedata as JSON, use the Get file metadata as JSON reporter.

To check if a file is currently open, use the Is file opened? boolean.

To check if the browser supports Direct Access (File System Access), use the Browser supports Direct Access? boolean.

Lastly, to close a flie you can use Close File.

About

A simple Turbowarp extension that uses the File System Access API to dynamically update files.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published