Skip to content

Add howto for local clone #569

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

Open
wants to merge 21 commits into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
70 changes: 63 additions & 7 deletions en/contributing/README.md
Original file line number Diff line number Diff line change
@@ -1,16 +1,73 @@
# Contribute to JabRef
# Contribute to JabRef [![Join the chat at https://gitter.im/JabRef/jabref](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/JabRef/jabref)

We are really happy that you are interested in contributing to JabRef. Please take your time to look around here. We especially invite you to look into our [community members page](https://discourse.jabref.org/t/community-members/1868?u=koppor) where members introduce themselves.

**I would like to improve the help page. What are the steps?** [![Join the chat at https://gitter.im/JabRef/jabref](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/JabRef/jabref)
## I would like to try out a feature introduced at pull request.

Check failure on line 5 in en/contributing/README.md

View workflow job for this annotation

GitHub Actions / lint

Trailing punctuation in heading [Punctuation: '.']

en/contributing/README.md:5:64 MD026/no-trailing-punctuation Trailing punctuation in heading [Punctuation: '.']

Please use the "Edit on GitHub" link in the upper right corner. Then, follow [GitHub's guide to edit files in other user's repository](https://docs.github.com/en/repositories/working-with-files/managing-files/editing-files#editing-files-in-another-users-repository).
In JabRef, there are dozens of bug fixes and new features introduced using GitHub's pull request mechansim.
You can browse all at <https://github.com/JabRef/jabref/pulls>.
The JabRef team really welcomes users to try out these changes and to comment on them.
Improving on changes in active pull requests is much easier than fixing them later on after their acceptance.

**I would like to help to translate JabRef to another language. How do I get started?** [![Join the chat at https://gitter.im/JabRef/jabref](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/JabRef/jabref)
If you are familiar with the command line on your OS, then it is very easy to try out pull requests and give feedback.
In the following, we try to give a minimal set of installation instructions to be able to run a contribution from a fork.

Required tooling:

- [GitHubCLI](https://cli.github.com/) - A command-line client for GitHub. You can install it using the installer linked on their [homepage](https://cli.github.com/) or the commands given at the [installation hints](https://github.com/cli/cli#installation).
- [`gg.cmd`](https://github.com/eirikb/gg) - A cross-platform and cross-architecture version manager. Download [`gg.cmd`](https://github.com/eirikb/gg/releases/latest/download/gg.cmd) and store it in your home (or `Downloads`) directory.

Initial setup:

- Windows:
- Open PowerShell
- Switch to a directory containing git repositories. We recommend `c:\git-repositories`
- `mkdir c:\git-repositories`
- `cd c:\git-repositories`
- Get `gg.cmd`
- `wget ggcmd.io -OutFile gg.cmd`
- Clone JabRef
- `./gg.cmd jbang https://github.com/JabRef/jabref/blob/main/.jbang/CloneJabRef.java JabRef`
- Make `gg.cmd` available in `JabRef` directory
- `cd JabRef`
- `move ..\gg.cmd .`
- Linux:
- Open a shell
- Switch to a directory containing git repositories. We recommend `~/git-repositories`
- `mkdir ~/git-repositories`
- `cd ~/git-repositories`
- Get `gg.cmd` (using either `wget` or `curl`)
- `wget ggcmd.io/gg.cmd`
- Alternative: `curl -L ggcmd.io > gg.cmd`
- Clone JabRef
- `sh ./gg.cmd jbang https://github.com/JabRef/jabref/blob/main/.jbang/CloneJabRef.java JabRef`
- NOTE: You can also use the native git client: `git clone --recurse-submodules https://github.com/JabRef/jabref.git JabRef` for achieving the same result.
- Make `gg.cmd` available in `JabRef` directory
- `cd JabRef`
- `mv ../gg.cmd .`

Now you are all set: You have a directory `JabRef` containing the recent updates and also `gg.cmd` which you will need later for executing a JabRef build.

Try a branch:

1. `cd` into the `JabRef` directory: `cd c:\git-repositories\JabRef`
2. Checkout out the pull request: `gh pr checkout 13111` - where `13111` is the PR number, in this case [pr#13111](https://github.com/JabRef/jabref/pull/13111).
3. Compile and run JabRef: `gg.cmd gradle run :jabgui:run` (on Linux and macOS, you need to prefix it with `sh`: `gg.cmd gradle run :jabgui:run`). This will also download the necessary JDK and gradle distribution. On the first run, please give the system enough time to accommodate and wait until the JabRef window launches. Depending on your hardware, this may take minutes.

Alternatives:

1. You don't want to use `gg.cmd`: You have the project clone ready and have some Java JDK available: In the `JabRef` directory, execute `./gradlew run`.
2. You don't want to use GitHub's `gh` tool: You can use the "usual" `git clone ...`, `git remote add ...`, `git fetch ...`, and `git checkout ...` commands to checkout a pull request from a fork.

**I would like to improve the help page.**

Please see [How to Improve the Help Page](how-to-improve-the-help-page.md)

**I would like to help translating JabRef to another language.**

We encourage you to read about [translating the JabRef user interface](how-to-translate-the-ui.md).

**I want to keep Wikipedia pages up-to-date** [![Join the chat at https://gitter.im/JabRef/jabref](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/JabRef/jabref)
**I would like to keep Wikipedia pages up-to-date.**

JabRef improves -- and Wikipedia pages should keep up!

Expand All @@ -31,7 +88,7 @@

If there is no page for your own language, you can easily create one.

**I have some cool feature requests** [![Discourse](https://img.shields.io/badge/discourse-online-green.svg)](https://discourse.jabref.org/c/features/6)
**I have some cool feature requests.**

[Come discuss it!](http://discourse.jabref.org)

Expand All @@ -40,7 +97,6 @@
Donations keep us going! You can use PayPal or bank transfers. Your institution/company can contribute too, through bank transfer for example. All details are provided at [https://donations.jabref.org](https://donations.jabref.org).

Our team consists of volunteers. To provide better support, we are currently trying to get a funded developer on board. Please consider donating money!
{% endtab %}

**I would like to contribute code. How to?**

Expand Down
Loading