Giter Club home page Giter Club logo

lemmy_account_sync's Introduction

WARNING!!! THIS IS A WORK IN PROGRESS.

Feel free to use what I have. I am still working on it though.

I am open to suggestions. Also open to feedback since I am always learning how to code.

Sync Your Subscribed Lemmy Communities Between Multiple Accounts

This program will look at multiple accounts and try to sync them up.

Will let you treat different Lemmy instances like it's all one shared account in case your favorite instance is down, or to more easily move when needed.

Things That Should Get Synced

  1. Subscribed Communities
  2. Blocked Communities
  3. Blocked Users
  4. Account Settings

Configuration

The program is controlled by a configuration file. See "exampleconfig.ini" for an example of the format.

Copy the "exampleconfig.ini" file, paste it in the "src" folder, and rename to "myconfig.ini" and fill in your accounts like the example shows.

You can have as many accounts as you wish. Labels for accounts can be anything except "Default".

Whatever account has the name "Main Account" will be the source for syncing your user settings since I don't know how to tell which account has the most recent updates.

[Main Account]
Site = https://sh.itjust.works
User = Imauser
Password = apasswod

[Account 2]
Site = https://lemmy.ml
User = cooluser
Password = badpassword

Usage

Run "lemmy_sync.py" after creating and updating the configuration file.

I am using Python 3.11 for the code and you will need the "Requests" package at minimum to run.

pip install -r requirements.txt just to run the application.

pip install -r dev_requirements.txt if you want to follow same formatting/structure to contribute.

Thank You

Special thanks to https://github.com/wescode/lemmy_migrate for giving me the inspiration and base code to build from.

Thanks to https://github.com/LemmyNet/lemmy-js-client for having the types and URLs laid out well enough that I could reverse engineer it.

Other Notes

Unit tests aren't working/non-existant at the moment. So basically ignore the "tests" directory...

Feel free to contribute or make requests. This is a side project that I mostly did for myself, but I would love to help more people if I can. I won't guarantee I will get the time to fix anything though...

lemmy_account_sync's People

Contributors

ac5000 avatar manikandanuv avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

lemmy_account_sync's Issues

2FA

Confirm 2FA doesn't work.

Fix if possible.

Unsubscribe?

Does the sync also unsubscribe if the community subscription does not exist in the "Main Account"? If not, should it?

Example 1:

I run the script once. It subscribes "Account 1" to all the communities subscribed to by "Main Account."

Later, I unsubscribe from a community on "Main Account."

If I run the script again will that community subscription be removed from "Account 1"?

Example 2:

I run the script once. It subscribes "Account 1" to all the communities subscribed to by "Main Account."

The instance of "Main Account" temporarily goes offline, so I start using "Account 1."

I subscribe to a new community using "Account 1" before my "Main Account" instance is back online and I switch back.

If run the script again will that community subscription be removed from "Account 1," added to "Main Account," or remain on "Account 1" without being added to "Main Account"?

Make More User Friendly

Make the script/app more user friendly in terms of setup and use. Currently requires some knowledge of Python and code setup to get running.

Make it a single run executable/runs in a browser type of thing that requests user input to avoid config file.

Something that I could post releases with.

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.