Giter Site home page Giter Site logo

gmailfs's People

Contributors

lucastliu avatar ruji-xie avatar ruji-xie-467 avatar yueyingyang avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

wujimmy

gmailfs's Issues

Advanced Support for Sending Emails

  1. Create a folder where users can create and edit files (draft email). Implement corresponding FUSE APIs
  2. parse email receiver, email sender, email subject line, email content
  3. Send emails:
    3 possible ways
    • append a special string. e.g. <<<send>>>
    • when the user finishes writing the file, send the email in release()
    • move the draft to another folder

Split emails by having subdirectory in the inbox folder

If there are many emails in the inbox, have subfolders that each hold X emails. So if there are 10 emails, perhaps the first 5 emails will be in subfolder1, and the next 5 in subfolder2.

  • have a config file to config the size of subdirectory

quick actions

enable ease of use options like quick reply

deal with replies and email threads

Implement Cache

Implement a cache systCache most recently read (requested) emails

Cache (pre-fetch) the new emails

Keep the most recent 100 emails based on these 2 policies

We define “most recent” as:
For new emails: receive time
For old emails that are read: most recent user access time
Current plan: remove the cached emails on start up
Optional: After the program ends, cached email will remain and next time we will only update the new coming emails from the last execution.

Provide basic Gmail API interface

[Python]

Provide a way for the filesystem to speak with a real Gmail Account.

  • Includes initial code for setup, account authentication, and service connection

Hardcoded cache string

Code only works if you make your "cache" folder named "src"

This is due to 2 regex patterns that look for src/inbox

Milestone 1 Demo

Full functionality for gmailfs demo with real gmail account

  • Use gmailfs to see real list of inbox emails,

  • Be able to read contents of specific email

  • After receiving a real email, gmailfs reflects this update

  • Can send a real email to another address

Add FUSE APIs to read email

  1. store the message id in the stat data structure, and when user callcat filename, using the stat to get the message id

  2. read() in Gmailfs class

  • call gmail API to request a specific message in full format (get_mime_message)
  • usef.write() write into actual file
  • read the actual file to display the content

Get a list of emails from the inbox

Be able to see a list of emails from a real gmail inbox. Implemented by calling ls on the /inbox folder.

bugs:

  • remove the quotation at the beginning and the end

Todos:

  • store the email data somewhere on the local disk

Persist cache through restarts

Keep the cache in between restarts, just look for changes to update the cache, instead of clearing out and starting over

Support Multiple Instances

Currently there is only one unique Pub/Sub. So if computer1 is running gmailfs, and ack's an auto update, computer2 will never receive the update on their gmailfs (even if same account)

Store an email as a directory

Create directories when we get the email list (instead of one file representing one email)

Each “Email’s personal directory” could have:

The email subject + unique ID will be the name of the directory

A file with the text content in html format

A file with the text content in plaintext format

Attachments are each their own file

Another file with all of the raw MIME data

Another file with all of the raw MIME data

Basic email sending function

  1. Create a folder called "send". Send emails when users move their drafts to that folder. Users can only create files but cannot modify files. Implement corresponding FUSE APIs
  2. parse email receiver, email sender, email subject line, email content

Enable config user's email account and pwd

  • Have a config file(in a fixed format, defined by us) in the directory

  • read config file in the __init__ in Gmailfs and pass it into Gmail object constructor

  • possibly extend to other config options as well

  • uses Google OAuth token instead of email / pwd

Implement Automatic Updating

Need to automatically look for new incoming emails, and have any changes reflected in gmailfs.

Two options:

1. poll Gmail API every x seconds and just look at the recent emails

  1. Develop a pub / sub function (watch API) whereby Gmail notifies gmailfs whenever there is a new email.

There are special cache implications for either of these choices.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.