Skip to content
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

Git like feature in course download folder #46

Open
HumHongeKamyaab opened this issue Aug 26, 2020 · 4 comments
Open

Git like feature in course download folder #46

HumHongeKamyaab opened this issue Aug 26, 2020 · 4 comments
Labels
Elaborate enhancement New feature or request (But it is costly, PR is seen with pleasure.)

Comments

@HumHongeKamyaab
Copy link

It is continuation of issue #43. It more makes sense to use the git approach for folder version management in downloaded course folder.
It will automatically add features to solve the issue of accidental file/folder deletion.
May be it is better that if each course can be treated independently, for e.g.,

$ python3 main.py --pull "$(courseid)" # will update the course content for id $(courseid)
$ python3 main.py --status "$(courseid)" # show status as git status
$ python3 main.py --checkout $(courseid) $(logid) # restore to old log id like git checkout
$ python3 main.py --rm $(some_individual_file) # like git rm
@C0D3D3V
Copy link
Owner

C0D3D3V commented Aug 26, 2020

Ah, now I see what you mean. Yeah, those would be really cool features.

@HumHongeKamyaab
Copy link
Author

On second thought, I think it is much easier if main.py function automatically make local git repository for each course folder when first time it is called and make a first commit for it.
So each time main.py is run, all the course folder will be updated and new commit will be made in each repository with some predefined message syntax.
Now user can manage each course folder with git, without any interference with main.py.

Just to clarify, main.py will work as git clone, pull and commit each time it run depending on context.

@C0D3D3V C0D3D3V added Elaborate enhancement New feature or request (But it is costly, PR is seen with pleasure.) and removed feature request labels Oct 6, 2021
@septatrix
Copy link

I think the simplest solution would be create a single repository manually and write your own simple shell wrapper which would call moodle-dl and afterwards calls add and commit with e.g. a timestamp as a commit message.

@C0D3D3V C0D3D3V changed the title [Feature Request] Git like feature in course download folder Git like feature in course download folder Mar 3, 2023
@C0D3D3V
Copy link
Owner

C0D3D3V commented Mar 18, 2023

This downloader kind of implemented the ideas you had (only in a other way, maybe more usefull)
https://github.com/omareldeeb/tum-moodle-downloader
Actually I still do not get your idea fully. maybe you also just wanted these commands for the moodle-dl database...

I do not want to work on such a feature, I do not see a good reason in it. If someone is intrested in it, do a PR, but first describe what you want to implement.

jonas-t-s already showed in his PR how to implement git repo actions, but that is not what you really want (And I also do not really want it).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Elaborate enhancement New feature or request (But it is costly, PR is seen with pleasure.)
Projects
No open projects
Development

No branches or pull requests

3 participants