-
Notifications
You must be signed in to change notification settings - Fork 9
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
Documentation update #110
Open
TomekRD
wants to merge
4
commits into
main
Choose a base branch
from
Documentation-Update
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Documentation update #110
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,75 @@ | ||
--- | ||
name: Anleitung für Abgabe | ||
index: 10 | ||
--- | ||
|
||
# Computerspieler abgabefertig machen (Anleitung für Export aus der IDE für Java) | ||
|
||
Im folgenden findet ihr eine Anleitung wie man seinen | ||
fertigen Client aus seiner Entwicklungsumgebung exportieren | ||
kann, um ihn im Wettkampfsystem hochladen zu könen. | ||
|
||
## Grundsätzliches | ||
Der Export des Projektes funktioniert für Java bei unserem Projekt | ||
über Gradle. Hierbei wird die Gradle Task "shadowJar" verwendet. </br> | ||
Wie genau das aussieht wird für Eclipse und IntelliJ im Folgenden beschrieben. | ||
|
||
## Eclipse | ||
Um den Export in Eclipse durchzuführen, muss man die Übersicht | ||
der Gradle Tasks öffnen. Um dies zu tun gibt es zwei Wege: | ||
|
||
1. Der erste Weg, wie die Übersicht geöffnet werden kann, ist in | ||
dem man auf das Gradle-Symbol (Elephant) klickt. | ||
Dieses Symbol ist am linken Rand zu finden. Es kann sein, | ||
dass das Symbol im Darkmode sehr schwer zu erkennen ist. | ||
|
||
2. Wenn man die Übersicht nicht finden kann oder das Symbol nicht existiert, | ||
kann die Übersicht geöffnet werden, in dem man oben auf | ||
Window/Show view/Other.../Gradle/Gradle Tasks geht und dann einen | ||
Doppelklick darauf macht oder es auswählt und unten auf "open" klickt. | ||
</br></br> | ||
|
||
Wenn die Gradle Tasks geöffnet sind, müssen folgende Schritte ausgeführt werden: | ||
1. Man geht auf den Ordner mit dem Namen des Projekts. Dieser ist standardmäßig | ||
"player-Spielkürzel-src" | ||
|
||
>Falls dort ein X an der Datei zu finden ist, müssen die Gradle Tasks einmal | ||
neugeladen werden. </br> Dies geschiet durch den Button "Refresh Tasks for | ||
all Projects" | ||
|
||
2. Unter dem nun angezeigten Inhalt ist ein Ordner | ||
der "shadow" heißt, den man nun öffnet | ||
|
||
3. In dem Ordner "shadow" befindet sich eine Task, die shadowJar heißt. | ||
Wenn nun Doppelklick auf die Task macht wird das Projekt in Form eines | ||
"Executable Jar File" exportiert. | ||
|
||
|
||
Der Export wird in dem Ordner des Projektes gespeichert. Der Name dieser Jar | ||
ist standardmäßig auf "Spielkürzel_Jahreszahl_client" kann aber nach dem Export | ||
beliebig geändert werden. Man kann den Namen auch vor dem Export anpassen, | ||
wenn man in dem Projekt "build.gradle.kts" öffnet und unter | ||
"tasks.shadowJar" den "archiveBaseName" ändert. | ||
|
||
|
||
## IntelliJ | ||
Um den Export in IntelliJ durchzuführen, muss man die Übersicht der Gradle Tasks öffnen. | ||
Dies geschieht, in dem man auf das Gradle-Symbol (Elephant) am rechten Rand klickt. | ||
Nun kann man die Gradle Task unterschiedlich ausführen. Im folgenden werden | ||
beide Varianten erläutert: | ||
|
||
1. Die kurze Variante über die Konsole: | ||
1. Man klickt auf das Konsolen-Symbol (Execute Gradle Task) | ||
2. In der offenen Konsole gibt man nun "shadowJar" ein | ||
3. Man druckt auf Enter | ||
|
||
2. Die lange Variante | ||
1. Man geht auf dem Ordner mit dem Namen des Projekts. Dieser ist standardmäßig "player-Spielkürzel-src" | ||
2. Unter dem nun angezeigten Inhalt ist ein Ordner der "shadow" heißt, den man nun öffnet | ||
3. In dem Ordner "shadow" befindet sich eine Task, die shadowJar heißt. Wenn man dort nun einen | ||
Doppelklick drauf macht wird das Projekt in Form eines "Executable Jar File" exportiert. | ||
|
||
Der Export wird in dem Ordner des Projektes gespeichert. Der Name dieser Jar ist | ||
standardmäßig auf "Spielkürzel_Jahreszahl_client" kann aber nach dem Export beliebig | ||
geändert werden. Man kann den Namen auch vor dem Export anpassen, wenn man in dem Projekt | ||
"build.gradle.kts" öffnet und unter "tasks.shadowJar" den "archiveBaseName" ändert. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
to be checked warum es bei 17 auf windows nicht funktioniert
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Auf 17 läuft es nicht, da die Gradle Version 6.9.1 die unsere Spielervorlage verwendet nur JDK´s bis 15 Supportet