Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/develop' into develop
Browse files Browse the repository at this point in the history
  • Loading branch information
florian-glombik committed Nov 8, 2024
2 parents 9b954b2 + 3bff129 commit c9ca46b
Show file tree
Hide file tree
Showing 108 changed files with 3,088 additions and 337 deletions.
1 change: 1 addition & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -249,6 +249,7 @@ dependencies {

implementation "de.jplag:c:${jplag_version}"
implementation "de.jplag:cpp:${jplag_version}"
implementation "de.jplag:csharp:${jplag_version}"
implementation "de.jplag:java:${jplag_version}"
implementation "de.jplag:javascript:${jplag_version}"
implementation "de.jplag:kotlin:${jplag_version}"
Expand Down
3 changes: 1 addition & 2 deletions docs/user/adaptive-learning/adaptive-learning-instructor.rst
Original file line number Diff line number Diff line change
Expand Up @@ -51,11 +51,10 @@ Create/Edit Competencies
Besides a title and description, they can set a `taxonomy <https://en.wikipedia.org/wiki/Bloom%27s_taxonomy>`_.
| The mastery threshold describes the minimum mastery required for a student to consider the competency as mastered.
The current average mastery shown on this page can be used as a basis for defining a reasonable threshold value.
| Instructors can link competencies to lecture units on this page by first choosing a lecture and then selecting desired lecture units.
|instructor-competency-edit|

Alternatively, instructors can also link competencies to an exercise or lecture unit on the respective management page using the selection box shown below.
Instructors can link competencies to an exercise or lecture unit on the respective management page using the selection box shown below.

|instructor-competency-link|

Expand Down
Binary file modified docs/user/adaptive-learning/instructor/competency-edit.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/user/exams/instructor/programming_assessment.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/user/exercises/modeling/create-modeling-exercise-form-3.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 4 additions & 0 deletions docs/user/exercises/programming-exercise-features.inc
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ Instructors can still use those templates to generate programming exercises and
+----------------------+----------+---------+
| TypeScript | yes | yes |
+----------------------+----------+---------+
| C# | yes | yes |
+----------------------+----------+---------+

- Not all ``templates`` support the same feature set and supported features can also change depending on the continuous integration system setup.
Depending on the feature set, some options might not be available during the creation of the programming exercise.
Expand Down Expand Up @@ -83,6 +85,8 @@ Instructors can still use those templates to generate programming exercises and
+----------------------+----------------------+----------------------+---------------------+--------------+------------------------------------------+------------------------------+----------------------------+------------------------+
| TypeScript | no | no | yes | no | n/a | no | no | L: yes, J: no |
+----------------------+----------------------+----------------------+---------------------+--------------+------------------------------------------+------------------------------+----------------------------+------------------------+
| C# | no | no | yes | no | n/a | no | no | L: yes, J: no |
+----------------------+----------------------+----------------------+---------------------+--------------+------------------------------------------+------------------------------+----------------------------+------------------------+

- *Sequential Test Runs*: ``Artemis`` can generate a build plan which first executes structural and then behavioral tests. This feature can help students to better concentrate on the immediate challenge at hand.
- *Static Code Analysis*: ``Artemis`` can generate a build plan which additionally executes static code analysis tools.
Expand Down
Binary file modified docs/user/exercises/programming/CodeEditor.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/user/exercises/programming/instructor-editor.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/user/exercises/programming/online-editor-assessment.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/user/exercises/programming/online-editor-feedback.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/user/exercises/programming/programming-edit-status.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/user/exercises/quiz/drag-and-drop-question.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/user/exercises/quiz/multiple-choice-question.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/user/exercises/quiz/short-answer-question.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/user/exercises/text/create-text-exercise-form-2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/user/icl/local-vc/commit-diff-view.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/user/icl/local-vc/current-repository-content-view.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
30 changes: 15 additions & 15 deletions docs/user/lectures.rst
Original file line number Diff line number Diff line change
Expand Up @@ -154,44 +154,44 @@ See :ref:`Adaptive Learning <adaptive-learning>` for more information.


.. |lectures-overview| image:: lectures/lectures-overview.png
:width: 800
:width: 1000
.. |lecture-details| image:: lectures/lecture-details.png
:width: 800
:width: 1000
.. |lectures-management| image:: lectures/lectures-management.png
:width: 800
:width: 1000
.. |lectures-management-btn| image:: lectures/lectures-management-button.png
:width: 80
.. |create-lecture| image:: lectures/create-lecture.png
:width: 800
:width: 1000
.. |create-lecture-btn| image:: lectures/create-lecture-button.png
:width: 120
.. |switch-to-guided-mode-btn| image:: lectures/switch-to-guided-mode-button.png
:width: 160
.. |create-attachment| image:: lectures/create-attachment.png
:width: 800
:width: 1000
.. |import-lecture| image:: lectures/import-lecture.png
:width: 800
:width: 1000
.. |import-lecture-btn| image:: lectures/import-lecture-button.png
:width: 120
.. |units-management-empty| image:: lectures/units-management-empty.png
:width: 800
:width: 1000
.. |units-management| image:: lectures/units-management.png
:width: 800
:width: 1000
.. |create-online-unit| image:: lectures/create-online-unit.png
:width: 800
:width: 1000
.. |create-text-unit| image:: lectures/create-text-unit.png
:width: 800
:width: 1000
.. |create-video-unit| image:: lectures/create-video-unit.png
:width: 800
:width: 1000
.. |create-attachment-unit| image:: lectures/create-attachment-unit.png
:width: 800
:width: 1000
.. |create-exercise-unit| image:: lectures/create-exercise-unit.png
:width: 800
:width: 1000
.. |process-units-checkbox| image:: lectures/process-units-checkbox.png
:width: 120
.. |process-units-btn| image:: lectures/process-units-btn.png
:width: 120
.. |processed-lecture-units| image:: lectures/processed-lecture-units.png
:width: 800
:width: 1000
.. |automatic-unit-processing| image:: lectures/automatic-unit-processing.png
:width: 800
:width: 1000
Binary file modified docs/user/lectures/automatic-unit-processing.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/user/lectures/create-attachment-unit.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/user/lectures/create-exercise-unit.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/user/lectures/create-lecture.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/user/lectures/create-online-unit.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/user/lectures/create-text-unit.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/user/lectures/create-video-unit.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/user/markdown-support/markdown-lecture-example.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/user/markdown-support/markdown-lecture-preview.png
Binary file modified docs/user/markdown-support/markdown-post-extensions-preview.png
Binary file modified docs/user/markdown-support/markdown-post-extensions.png
Binary file modified docs/user/tutorialgroups/instructors-tutorial-group-form.png
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
import de.jplag.c.CLanguage;
import de.jplag.clustering.ClusteringOptions;
import de.jplag.cpp.CPPLanguage;
import de.jplag.csharp.CSharpLanguage;
import de.jplag.exceptions.ExitException;
import de.jplag.java.JavaLanguage;
import de.jplag.javascript.JavaScriptLanguage;
Expand Down Expand Up @@ -315,6 +316,7 @@ private Language getJPlagProgrammingLanguage(ProgrammingExercise programmingExer
return switch (programmingExercise.getProgrammingLanguage()) {
case C -> new CLanguage();
case C_PLUS_PLUS -> new CPPLanguage();
case C_SHARP -> new CSharpLanguage();
case JAVA -> new JavaLanguage();
case JAVASCRIPT -> new JavaScriptLanguage();
case KOTLIN -> new KotlinLanguage();
Expand All @@ -323,7 +325,7 @@ private Language getJPlagProgrammingLanguage(ProgrammingExercise programmingExer
case RUST -> new RustLanguage();
case SWIFT -> new SwiftLanguage();
case TYPESCRIPT -> new TypeScriptLanguage();
case EMPTY, PHP, DART, HASKELL, ASSEMBLER, OCAML, C_SHARP, SQL, GO, MATLAB, BASH, VHDL, RUBY, POWERSHELL, ADA -> throw new BadRequestAlertException(
case EMPTY, PHP, DART, HASKELL, ASSEMBLER, OCAML, SQL, GO, MATLAB, BASH, VHDL, RUBY, POWERSHELL, ADA -> throw new BadRequestAlertException(
"Programming language " + programmingExercise.getProgrammingLanguage() + " not supported for plagiarism check.", "ProgrammingExercise", "notSupported");
};
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ public enum ProgrammingLanguage {
ASSEMBLER,
C,
C_PLUS_PLUS,
C_SHARP,
HASKELL,
JAVA,
JAVASCRIPT,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,8 @@ public TemplateUpgradePolicyService(JavaTemplateUpgradeService javaRepositoryUpg
public TemplateUpgradeService getUpgradeService(ProgrammingLanguage programmingLanguage) {
return switch (programmingLanguage) {
case JAVA -> javaRepositoryUpgradeService;
case KOTLIN, PYTHON, C, HASKELL, VHDL, ASSEMBLER, SWIFT, OCAML, EMPTY, RUST, JAVASCRIPT, R, C_PLUS_PLUS, TYPESCRIPT -> defaultRepositoryUpgradeService;
case C_SHARP, SQL, GO, MATLAB, BASH, RUBY, POWERSHELL, ADA, DART, PHP ->
throw new UnsupportedOperationException("Unsupported programming language: " + programmingLanguage);
case KOTLIN, PYTHON, C, HASKELL, VHDL, ASSEMBLER, SWIFT, OCAML, EMPTY, RUST, JAVASCRIPT, R, C_PLUS_PLUS, TYPESCRIPT, C_SHARP -> defaultRepositoryUpgradeService;
case SQL, GO, MATLAB, BASH, RUBY, POWERSHELL, ADA, DART, PHP -> throw new UnsupportedOperationException("Unsupported programming language: " + programmingLanguage);
};
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -219,9 +219,8 @@ enum RepositoryCheckoutPath implements CustomizableCheckoutPath {
@Override
public String forProgrammingLanguage(ProgrammingLanguage language) {
return switch (language) {
case JAVA, PYTHON, C, HASKELL, KOTLIN, VHDL, ASSEMBLER, SWIFT, OCAML, EMPTY, RUST, JAVASCRIPT, R, C_PLUS_PLUS, TYPESCRIPT -> "assignment";
case C_SHARP, SQL, GO, MATLAB, BASH, RUBY, POWERSHELL, ADA, DART, PHP ->
throw new UnsupportedOperationException("Unsupported programming language: " + language);
case JAVA, PYTHON, C, HASKELL, KOTLIN, VHDL, ASSEMBLER, SWIFT, OCAML, EMPTY, RUST, JAVASCRIPT, R, C_PLUS_PLUS, TYPESCRIPT, C_SHARP -> "assignment";
case SQL, GO, MATLAB, BASH, RUBY, POWERSHELL, ADA, DART, PHP -> throw new UnsupportedOperationException("Unsupported programming language: " + language);
};
}
},
Expand All @@ -231,9 +230,8 @@ public String forProgrammingLanguage(ProgrammingLanguage language) {
public String forProgrammingLanguage(ProgrammingLanguage language) {
return switch (language) {
case JAVA, PYTHON, HASKELL, KOTLIN, SWIFT, EMPTY, RUST, JAVASCRIPT, R, C_PLUS_PLUS, TYPESCRIPT -> "";
case C, VHDL, ASSEMBLER, OCAML -> "tests";
case C_SHARP, SQL, GO, MATLAB, BASH, RUBY, POWERSHELL, ADA, DART, PHP ->
throw new UnsupportedOperationException("Unsupported programming language: " + language);
case C, VHDL, ASSEMBLER, OCAML, C_SHARP -> "tests";
case SQL, GO, MATLAB, BASH, RUBY, POWERSHELL, ADA, DART, PHP -> throw new UnsupportedOperationException("Unsupported programming language: " + language);
};
}
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import static de.tum.cit.aet.artemis.programming.domain.ProgrammingLanguage.C;
import static de.tum.cit.aet.artemis.programming.domain.ProgrammingLanguage.C_PLUS_PLUS;
import static de.tum.cit.aet.artemis.programming.domain.ProgrammingLanguage.C_SHARP;
import static de.tum.cit.aet.artemis.programming.domain.ProgrammingLanguage.EMPTY;
import static de.tum.cit.aet.artemis.programming.domain.ProgrammingLanguage.HASKELL;
import static de.tum.cit.aet.artemis.programming.domain.ProgrammingLanguage.JAVA;
Expand Down Expand Up @@ -38,6 +39,7 @@ public JenkinsProgrammingLanguageFeatureService() {
programmingLanguageFeatures.put(EMPTY, new ProgrammingLanguageFeature(EMPTY, false, false, false, false, false, List.of(), false, false));
programmingLanguageFeatures.put(C, new ProgrammingLanguageFeature(C, false, false, true, false, false, List.of(FACT, GCC), false, false));
programmingLanguageFeatures.put(C_PLUS_PLUS, new ProgrammingLanguageFeature(C_PLUS_PLUS, false, false, true, false, false, List.of(), false, false));
programmingLanguageFeatures.put(C_SHARP, new ProgrammingLanguageFeature(C_SHARP, false, false, true, false, false, List.of(), false, false));
programmingLanguageFeatures.put(HASKELL, new ProgrammingLanguageFeature(HASKELL, false, false, false, false, true, List.of(), false, false));
programmingLanguageFeatures.put(JAVA,
new ProgrammingLanguageFeature(JAVA, true, true, true, true, false, List.of(PLAIN_GRADLE, GRADLE_GRADLE, PLAIN_MAVEN, MAVEN_MAVEN, MAVEN_BLACKBOX), true, false));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -184,8 +184,8 @@ private JenkinsXmlConfigBuilder builderFor(ProgrammingLanguage programmingLangua
throw new UnsupportedOperationException("Xcode templates are not available for Jenkins.");
}
return switch (programmingLanguage) {
case JAVA, KOTLIN, PYTHON, C, HASKELL, SWIFT, EMPTY, RUST, JAVASCRIPT, R, C_PLUS_PLUS, TYPESCRIPT -> jenkinsBuildPlanCreator;
case VHDL, ASSEMBLER, OCAML, C_SHARP, SQL, GO, MATLAB, BASH, RUBY, POWERSHELL, ADA, DART, PHP ->
case JAVA, KOTLIN, PYTHON, C, HASKELL, SWIFT, EMPTY, RUST, JAVASCRIPT, R, C_PLUS_PLUS, TYPESCRIPT, C_SHARP -> jenkinsBuildPlanCreator;
case VHDL, ASSEMBLER, OCAML, SQL, GO, MATLAB, BASH, RUBY, POWERSHELL, ADA, DART, PHP ->
throw new UnsupportedOperationException(programmingLanguage + " templates are not available for Jenkins.");
};
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
import static de.tum.cit.aet.artemis.programming.domain.ProgrammingLanguage.ASSEMBLER;
import static de.tum.cit.aet.artemis.programming.domain.ProgrammingLanguage.C;
import static de.tum.cit.aet.artemis.programming.domain.ProgrammingLanguage.C_PLUS_PLUS;
import static de.tum.cit.aet.artemis.programming.domain.ProgrammingLanguage.C_SHARP;
import static de.tum.cit.aet.artemis.programming.domain.ProgrammingLanguage.EMPTY;
import static de.tum.cit.aet.artemis.programming.domain.ProgrammingLanguage.HASKELL;
import static de.tum.cit.aet.artemis.programming.domain.ProgrammingLanguage.JAVA;
Expand Down Expand Up @@ -45,6 +46,7 @@ public LocalCIProgrammingLanguageFeatureService() {
programmingLanguageFeatures.put(ASSEMBLER, new ProgrammingLanguageFeature(ASSEMBLER, false, false, false, false, false, List.of(), false, true));
programmingLanguageFeatures.put(C, new ProgrammingLanguageFeature(C, false, true, true, false, false, List.of(FACT, GCC), false, true));
programmingLanguageFeatures.put(C_PLUS_PLUS, new ProgrammingLanguageFeature(C_PLUS_PLUS, false, false, true, false, false, List.of(), false, true));
programmingLanguageFeatures.put(C_SHARP, new ProgrammingLanguageFeature(C_SHARP, false, false, true, false, false, List.of(), false, true));
programmingLanguageFeatures.put(HASKELL, new ProgrammingLanguageFeature(HASKELL, true, false, false, false, true, List.of(), false, true));
programmingLanguageFeatures.put(JAVA,
new ProgrammingLanguageFeature(JAVA, true, true, true, true, false, List.of(PLAIN_GRADLE, GRADLE_GRADLE, PLAIN_MAVEN, MAVEN_MAVEN), false, true));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,8 @@ private QuizExercise copyQuizExerciseBasis(QuizExercise importedExercise) {
newExercise.setRandomizeQuestionOrder(importedExercise.isRandomizeQuestionOrder());
newExercise.setAllowedNumberOfAttempts(importedExercise.getAllowedNumberOfAttempts());
newExercise.setRemainingNumberOfAttempts(importedExercise.getRemainingNumberOfAttempts());
newExercise.setIsOpenForPractice(importedExercise.isIsOpenForPractice());
// The new exercise should not immediately be open for practice
newExercise.setIsOpenForPractice(false);
newExercise.setQuizMode(importedExercise.getQuizMode());
newExercise.setDuration(importedExercise.getDuration());
return newExercise;
Expand Down
4 changes: 3 additions & 1 deletion src/main/resources/config/application.yml
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ artemis:
default: "ls1tum/artemis-c-docker:latest"
fact: "sharingcodeability/fact:latest"
haskell:
default: "ghcr.io/uni-passau-artemis/artemis-haskell:v19.33.0"
default: "ghcr.io/uni-passau-artemis/artemis-haskell:v22.37.0"
vhdl:
default: "tizianleonhardt/era-artemis-vhdl:latest"
assembler:
Expand All @@ -95,6 +95,8 @@ artemis:
default: "ghcr.io/ls1intum/artemis-r-docker:v1.0.0"
c_plus_plus:
default: "ghcr.io/ls1intum/artemis-cpp-docker:v1.0.0"
c_sharp:
default: "ghcr.io/ls1intum/artemis-csharp-docker:v1.0.0"
typescript:
default: "ghcr.io/ls1intum/artemis-javascript-docker:v1.0.0"

Expand Down
26 changes: 26 additions & 0 deletions src/main/resources/templates/aeolus/c_sharp/default.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
#!/usr/bin/env bash
set -e
export AEOLUS_INITIAL_DIRECTORY=${PWD}
build () {
echo '⚙️ executing build'
dotnet build "${testWorkingDirectory}"
}

test () {
echo '⚙️ executing test'
dotnet test --logger=junit "${testWorkingDirectory}"
}

main () {
if [[ "${1}" == "aeolus_sourcing" ]]; then
return 0 # just source to use the methods in the subshell, no execution
fi
local _script_name
_script_name=${BASH_SOURCE[0]:-$0}
cd "${AEOLUS_INITIAL_DIRECTORY}"
bash -c "source ${_script_name} aeolus_sourcing; build"
cd "${AEOLUS_INITIAL_DIRECTORY}"
bash -c "source ${_script_name} aeolus_sourcing; test"
}

main "${@}"
13 changes: 13 additions & 0 deletions src/main/resources/templates/aeolus/c_sharp/default.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
api: v0.0.1
metadata:
name: "C#"
id: c_sharp
actions:
- name: build
script: dotnet build "${testWorkingDirectory}"
- name: test
script: dotnet test --logger=junit "${testWorkingDirectory}"
results:
- name: NUnit Test Results
path: "${testWorkingDirectory}/TestResults/TestResults.xml"
type: junit
Loading

0 comments on commit c9ca46b

Please sign in to comment.