From 2dac8055b8a085aaeee57e172873b0adc5b38e72 Mon Sep 17 00:00:00 2001 From: "github-classroom[bot]" <66690702+github-classroom[bot]@users.noreply.github.com> Date: Mon, 23 Sep 2024 13:34:02 +0000 Subject: [PATCH 1/4] GitHub Classroom Autograding Workflow --- .github/workflows/classroom.yml | 75 +++++++++++++++++++++++++++++++++ 1 file changed, 75 insertions(+) create mode 100644 .github/workflows/classroom.yml diff --git a/.github/workflows/classroom.yml b/.github/workflows/classroom.yml new file mode 100644 index 000000000..6e5e66840 --- /dev/null +++ b/.github/workflows/classroom.yml @@ -0,0 +1,75 @@ +name: Autograding Tests +'on': +- workflow_dispatch +- repository_dispatch +permissions: + checks: write + actions: read + contents: read +jobs: + run-autograding-tests: + runs-on: ubuntu-latest + if: github.actor != 'github-classroom[bot]' + steps: + - name: Checkout code + uses: actions/checkout@v4 + - name: Step 1 Add Headers + id: step-1-add-headers + uses: classroom-resources/autograding-command-grader@v1 + with: + test-name: Step 1 Add Headers + setup-command: sleep 20 + command: "[ $(cat .github/script/STEP) -ge 1 ] || [ $(cat .github/script/STEP) + = X ]" + timeout: 10 + max-score: 1 + - name: Step 2 Add an image + id: step-2-add-an-image + uses: classroom-resources/autograding-command-grader@v1 + with: + test-name: Step 2 Add an image + setup-command: sleep 20 + command: "[ $(cat .github/script/STEP) -ge 2 ] || [ $(cat .github/script/STEP) + = X ]" + timeout: 10 + max-score: 1 + - name: Step 3 Add a code example + id: step-3-add-a-code-example + uses: classroom-resources/autograding-command-grader@v1 + with: + test-name: Step 3 Add a code example + setup-command: sleep 20 + command: "[ $(cat .github/script/STEP) -ge 3 ] || [ $(cat .github/script/STEP) + = X ]" + timeout: 10 + max-score: 1 + - name: Step 4 Make a task list + id: step-4-make-a-task-list + uses: classroom-resources/autograding-command-grader@v1 + with: + test-name: Step 4 Make a task list + setup-command: sleep 20 + command: "[ $(cat .github/script/STEP) -ge 4 ] || [ $(cat .github/script/STEP) + = X ]" + timeout: 10 + max-score: 1 + - name: Step 5 Merge your pull request + id: step-5-merge-your-pull-request + uses: classroom-resources/autograding-command-grader@v1 + with: + test-name: Step 5 Merge your pull request + setup-command: sleep 20 + command: "[ $(cat .github/script/STEP) -ge 5 ] || [ $(cat .github/script/STEP) + = X ]" + timeout: 10 + max-score: 1 + - name: Autograding Reporter + uses: classroom-resources/autograding-grading-reporter@v1 + env: + STEP-1-ADD-HEADERS_RESULTS: "${{steps.step-1-add-headers.outputs.result}}" + STEP-2-ADD-AN-IMAGE_RESULTS: "${{steps.step-2-add-an-image.outputs.result}}" + STEP-3-ADD-A-CODE-EXAMPLE_RESULTS: "${{steps.step-3-add-a-code-example.outputs.result}}" + STEP-4-MAKE-A-TASK-LIST_RESULTS: "${{steps.step-4-make-a-task-list.outputs.result}}" + STEP-5-MERGE-YOUR-PULL-REQUEST_RESULTS: "${{steps.step-5-merge-your-pull-request.outputs.result}}" + with: + runners: step-1-add-headers,step-2-add-an-image,step-3-add-a-code-example,step-4-make-a-task-list,step-5-merge-your-pull-request From 3f7cd2e651ff03031bcbc2ce36569517aea0fc87 Mon Sep 17 00:00:00 2001 From: github-actions Date: Mon, 23 Sep 2024 13:34:29 +0000 Subject: [PATCH 2/4] Update to 1 in STEP and README.md --- .github/script/STEP | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/script/STEP b/.github/script/STEP index 573541ac9..d00491fd7 100644 --- a/.github/script/STEP +++ b/.github/script/STEP @@ -1 +1 @@ -0 +1 From 689797360d3b07f4e57290668fbeb2720c594b02 Mon Sep 17 00:00:00 2001 From: KevinSidd Date: Mon, 23 Sep 2024 19:38:40 +0530 Subject: [PATCH 3/4] Wow this is the first commit! --- index.md | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 index.md diff --git a/index.md b/index.md new file mode 100644 index 000000000..5fdc5ecff --- /dev/null +++ b/index.md @@ -0,0 +1,20 @@ +# This is a test header for `H1` +## This is a test header for `H2` +###### This is a test header for `H6` + +![Image of Yaktocat](https://cdn.discordapp.com/attachments/1041951848107614229/1287776953557848095/OMEN.jpg?ex=66f2c73f&is=66f175bf&hm=68ef62c7edab1df1b6b78be772dd757f4dcf6903166b4a50abfd367ba5f9da5a&) + +```ts +function addNumbers(input: string) { + const numbers = input.split(',').map(n => parseInt(n)); + if (!numbers.length) { + throw new Error('No numbers provided, make sure the input is a string of numbers separated by commas'); + } + + return numbers.reduce((total, n) => total + n); +} +``` + +- [x] I want to die +- [x] Sometimes it's like going through hell +- [ ] Life is complete 😃 \ No newline at end of file From d334cbbddd8ae2c2c7fe683830ca9d11dfd43bdb Mon Sep 17 00:00:00 2001 From: KevinSidd Date: Mon, 23 Sep 2024 20:09:43 +0530 Subject: [PATCH 4/4] Added some content --- index.md | 54 +++++++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 53 insertions(+), 1 deletion(-) diff --git a/index.md b/index.md index 5fdc5ecff..e24b3b282 100644 --- a/index.md +++ b/index.md @@ -1,9 +1,19 @@ +### Headers + # This is a test header for `H1` ## This is a test header for `H2` ###### This is a test header for `H6` +--- + +### Showing Image + ![Image of Yaktocat](https://cdn.discordapp.com/attachments/1041951848107614229/1287776953557848095/OMEN.jpg?ex=66f2c73f&is=66f175bf&hm=68ef62c7edab1df1b6b78be772dd757f4dcf6903166b4a50abfd367ba5f9da5a&) +--- + +### Adding code blocks + ```ts function addNumbers(input: string) { const numbers = input.split(',').map(n => parseInt(n)); @@ -15,6 +25,48 @@ function addNumbers(input: string) { } ``` +--- + +### Listing + - [x] I want to die - [x] Sometimes it's like going through hell -- [ ] Life is complete 😃 \ No newline at end of file +- [ ] Life is complete 😃 + +--- + +### Creating A Table + +| Something | Something | +| --------- | --------- | +| Cell | Cell | +| Cell | Cell | + +--- + +### Formatting content + +| Index | To use | Description | Example | +| :-----: | :-----: | :----------- | :-------: | +| 1 | `**` | Used to show content bold | `**Ello**` • **Ello** | +| 2 | `_` | Used to show content in italics | `_Kiwii_` • _Kiwii_ | +| 3 | `*` | Used to show content in italics | `*Kiwii 2*` • *Kiwii 2* | +| 4 | `` | Used to show an underline | `Text` • Text | + +--- + +### Creating a collapsed section + +
+This is an amazing section, click here to be amazed! + +### *Ofc we need a header for this section bruh* + +So let me tell you about this ***Amazing thing!*** +> You got tricked to click on it 🤣 + +```js +console.log("Bro got tricked, [+1] for Kevin!"); +``` + +
\ No newline at end of file