{"id":15888004,"url":"https://github.com/cehbrecht/gitforscience-sandbox","last_synced_at":"2026-04-21T16:38:53.747Z","repository":{"id":76761351,"uuid":"128832142","full_name":"cehbrecht/gitforscience-sandbox","owner":"cehbrecht","description":"Sandbox for Git-for-Science Workshop","archived":false,"fork":false,"pushed_at":"2018-04-10T23:14:42.000Z","size":1399,"stargazers_count":0,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-02T16:51:08.283Z","etag":null,"topics":["egu2018","git","latex","overleaf","workshop"],"latest_commit_sha":null,"homepage":null,"language":"TeX","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cehbrecht.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-04-09T20:50:09.000Z","updated_at":"2018-04-10T23:04:37.000Z","dependencies_parsed_at":null,"dependency_job_id":"6045a3a7-816c-49f1-8c16-fc23bf180173","html_url":"https://github.com/cehbrecht/gitforscience-sandbox","commit_stats":{"total_commits":40,"total_committers":2,"mean_commits":20.0,"dds":"0.050000000000000044","last_synced_commit":"da8f5cb48c42d977e34076b4208877f9922ca22a"},"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/cehbrecht/gitforscience-sandbox","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cehbrecht%2Fgitforscience-sandbox","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cehbrecht%2Fgitforscience-sandbox/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cehbrecht%2Fgitforscience-sandbox/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cehbrecht%2Fgitforscience-sandbox/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cehbrecht","download_url":"https://codeload.github.com/cehbrecht/gitforscience-sandbox/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cehbrecht%2Fgitforscience-sandbox/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":260419612,"owners_count":23006316,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["egu2018","git","latex","overleaf","workshop"],"created_at":"2024-10-06T06:06:01.894Z","updated_at":"2026-04-21T16:38:48.692Z","avatar_url":"https://github.com/cehbrecht.png","language":"TeX","funding_links":[],"categories":[],"sub_categories":[],"readme":"# gitforscience-sandbox\n\nSandbox for Git-for-Science Workshop.\n\n\n## Write LaTeX document using Overleaf and Git\n\n### Edit Overleaf document\n\nRead and Edit online:\nhttps://www.overleaf.com/15422340tzpscybmktkc\n\nRead only:\nhttps://www.overleaf.com/read/zncknkybdkxg\n\nGit clone to work offline:\n\n    $ git clone https://git.overleaf.com/15422340tzpscybmktkc\n\n### Push my Overleaf document to my GitHub repo\n\nCreate a Git repo on GitHub and clone it:\n\n    # Please create your own ... just showing the example with my sandbox\n    $ git clone git@github.com:cehbrecht/gitforscience-sandbox.git\n    $ cd gitforscience-sandbox\n\n\n**OR**\n\nCreate you own local Git repo:\n\n     $ mkdir gitforscience-sandbox\n     $ cd gitforscience-sandbox\n     $ git init\n\nAdd the overleaf git repo as remote:\n\n    $ git remote add overleaf https://git.overleaf.com/15422340tzpscybmktkc\n    $ git remote -v\n\nMake your repo identical to the overleaf repo. Be careful with this ... you will loose everything on your local master branch:\n\n    $ git reset --hard overleaf/master\n    # push it to your remote origin master ... if you have a remote\n    $ git push --force\n\n### Update Overleaf document with local changes\n\nEdit your Overleaf document locally:\n\n    $ atom main.tex  # choose your favorite LaTeX editor\n\nCommit your changes:\n\n     $ git status\n     $ git commit -a -m \"update\"\n     $ git push   # push to remote origin master if you have one\n\nPush your changes to Overleaf:\n\n    $ git pull overleaf master\n    $ git push overleaf master\n\n### Merge changes and handle conflicts\n\nFirst edit Overleaf document and the local document at different sections.\nUpdate your changes with the remote overleaf document. Changes will be merged automatically.\n\nNow make edits at the same text line locally and in overleaf. Update your changes again\nbut this time you will need to solve a merge conflict.   \n\n### Tag a version\n\nWith git you can tag a version:\n\n    $ git tag 0.1\n    $ git push --tags  # push all tags to your remote\n\nUse this tag to create a release on GitHub:\nhttps://help.github.com/articles/creating-releases/\n\n## Going further ...\n\n### Create a DOI to reference your paper\n\nUsing an online service you can create automatically a DOI for your paper on GitHub\nwhenever you make a new release:\n\nhttps://guides.github.com/activities/citable-code/\n\n### Handle large files with Git\n\nVersion controls are made for coding and can handle text files very well.\nThey can be used for binary files as well but this has some limitations.\nYou can use Git LFS extension on GitHub to get around these limitations. Large binary files will then be stored in an external storage and not in the Git repo itself. The Git repo has only pointers to these files.\n\nhttps://git-lfs.github.com/\n\n## But I have to use Word!\n\nNot a good choice ... but possible:\n\n* use Git LFS extension to handle binary files.\n* use pandoc: http://blog.martinfenner.org/2014/08/25/using-microsoft-word-with-git/\n\nResolve merge conflict with docx:\n* https://stackoverflow.com/questions/278081/resolving-a-git-conflict-with-binary-files\n* `git mergetool`\n* merge with Word: https://support.office.com/en-us/article/Combine-documents-f8f07f09-4461-4376-b041-89ad67412cfe\n* close merge editor\n\n## Links\n\nOverleaf:\n* https://www.overleaf.com/\n* Online collaborative LaTeX editor with integrated real-time preview.\n* Uses Git in the background.\n* Alternatives\n  * ShareLatex: https://www.sharelatex.com/\n  * Authorea (LaTeX and Markdown): https://www.authorea.com/\n\nGitHub:\n* https://github.com/\n* Online service for Git repositories and collaborative developing.\n\nGit:\n* https://git-scm.com/\n* Version control system for decentralised software development.\n\nLaTeX:\n* https://www.tug.org/texlive/\n* TexLive on macOS: https://www.tug.org/mactex/\n* On macOS install it with homebrew: http://yabas.net/blog/install-latex-on-mac-with-brew/\n* Write beautiful documents.\n\nEditors:\n* Atom: https://atom.io/\n\nDoc Converters:\n* Pandoc: https://pandoc.org/\n\nGood Alternatives to LaTeX:\n* Markdown: https://daringfireball.net/projects/markdown/\n  * Authorea: https://www.authorea.com/\n* Restructred Text: http://docutils.sourceforge.net/rst.html\n  * Sphinx: http://www.sphinx-doc.org/en/master/\n  * ReadTheDocs: https://readthedocs.org/\n\nUsing Overleaf with Jupyter Notebooks:\nhttps://medium.com/thoughts-philosophy-writing/how-to-update-overleaf-from-a-juypter-notebook-5469b1405fdc\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcehbrecht%2Fgitforscience-sandbox","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcehbrecht%2Fgitforscience-sandbox","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcehbrecht%2Fgitforscience-sandbox/lists"}