Skip to content

Instantly share code, notes, and snippets.

@Null-Austin
Last active September 26, 2025 15:14
Show Gist options
  • Select an option

  • Save Null-Austin/1f220b5573e4b12b5f17221ce8818871 to your computer and use it in GitHub Desktop.

Select an option

Save Null-Austin/1f220b5573e4b12b5f17221ce8818871 to your computer and use it in GitHub Desktop.
Public file explorer idea

Cool idea

So basically, a cool file server that is for public trust, so people trust the website. It will show the hashed content of files, and hide other files specific, to their name, path, or suffix (.env)

Pseudo code:

function getFiles(dir){ // a simple test function
    let _files = {
        "folders":[],
        "files":[]
    } // a simple list variable
    for file in dir.files{
        if (file.isFile){
            _files.files.append({"name":file.name,"content":hash(file.content)}) //hash the file content
        } else if (file.isFolder){
            _files.folders.append({"name":file.name})
        }
    }
    return _files // return the list!
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment