Closed abelgomez closed 7 years ago
If this PR is merged, the README.md file should be updated accordingly in the following sections:
https://github.com/Jorl17/sharelatex-git-integration-unofficial#sharelatex-git-integration-unofficial Indicate that any service is supported, remove references to public repositories.
https://github.com/Jorl17/sharelatex-git-integration-unofficial#quickstart-getting-started Remove references to public projects.
https://github.com/Jorl17/sharelatex-git-integration-unofficial#how-does-it-work-is-this-legal Remove references to public projects.
https://github.com/Jorl17/sharelatex-git-integration-unofficial#the-url-is-too-largecant-i-initialize-the-application-with-something-else Indicate that project ids refer to projects hosted on www.sharelatex.com
https://github.com/Jorl17/sharelatex-git-integration-unofficial#isnt-it-dangerous-to-make-my-project-public Indicate that non-public repositories are supported, and remove comment about opening a request.
https://github.com/Jorl17/sharelatex-git-integration-unofficial#what-are-all-the-options Add new options.
Hi! Thank you for your excellent work!
I am a bit busy at the moment, so I will look into this in the coming weekend (might make a couple of comments here and there through the remainder of the week).
I will take care of the changes to the README. I will also add you to the authors list on the main .py file (I will probably also add this project to PyPI). Do you have any particular e-mail you would like me to attach to the copyright notice?
One important note is that I might make some changes to retain backwards compatibility. I know of several people (back at my old university) who use this script and breaking backwards-compatibility is mostly a no-go. I'm also not very fond of adding dependencies on external libraries (for the same reason and the fact that some of these people are really not very tech-savvy and got "a friend of a friend to install this on their windows machines"), but I'll see what I can cook up.
Once again, thank you for your contribution! I'll check back in the weekend.
Ok, no problem!
Thank you for including me in the copyright notice, I was not expecting any additional credit for my contribution. Regarding the e-mail, if it's possible, I'd prefer if you just include the URL of my GitHub profile (https://github.com/abelgomez) instead of an e-mail. I change my public e-mail quite often.
With respect to the backwards compatibility, I thought that removing the .sharelatex-git
file and executing the script again with the needed parameters was not a big deal, and helped to maintain the code clean 😄.
Anyway, if this is a big issue, I can take charge of implementing the code to migrate files from the the old format to the new format automatically when needed.
Regarding the dependencies, to be fair, I didn't think on them. For sure the install script can be improved to take care of them if needed.
Let me know anything you may need from me!
In the latest commits, I have added a few fixes and I added support for the automatic migration of old-style .sharelatex-git files. Now all the modifications are backwards compatible.
Regarding the dependencies, I'll let you decide :)
FYI: the only additional dependencies are requests
and bs4
, both available via pip
. The first one is used to easily maintain HTTP sessions, needed for sites requiring authentication. The second one is used to easily parse the downloaded webpages (for example, to get the CSRF token, needed in the post message).
Hi! I have not forgotten about this. In the coming days I'll accept your excellent pull request with a couple of changes (mostly code-level changes, with the output being the same). I've just been a bit lazy about editing the README.
Thank you once again for your excellent work! :)
I have merged this PR and made the necessary adjustments to the README. If you have any issues, do say! I'm closing the PR for now.
Once again, thank you for your work! :)
Perfect! Many thanks!
BTW, I've found a small inconsistency here, where it's still stated that user/password is not supported.
Since this is already done, maybe I can find some time to implement the push to sharelatex if you think it's worth.
Cheers!
Done in 4ff7177d13bf9deaf15511598a306fba12d3a0a2 :) Thanks!
I had already started some work on push support, but that was about a year ago. Have a shot at it if you have time, then, please.
Cheers!
I'll let you know in that case!
This PR includes the following changes:
As the initial version, the argument can be either a project id or a full URL. When users provide a project ID, the program works as before (i.e., it is assumed that the project is hosted on https://www.sharelatex.com). When users provide a URL, the URL can point to any ShareLaTeX installation. Thus, not only projects on www.sharelatex.com are supported, but also self-hosted servers are supported.
Private projects are supported. Credentials can be provided using two additional arguments: [-e|--email] and [--password]. The password may be omitted. In such a case, the user will be always prompted for it. The password is NEVER stored on disk.
Format of .sharelatex-git files has changed to support any arbitrary set of configuration values (no backwards compatibility has been added to support the old format). Currently, url and email is being saved. Conflict handling procedure is maintained.
Deprecated code in "fetch_updates" has been removed.