Skip to content

Commit

Permalink
Start of Day 5
Browse files Browse the repository at this point in the history
  • Loading branch information
richelbilderbeek committed Oct 12, 2023
1 parent 58de4ff commit 80d9461
Show file tree
Hide file tree
Showing 36 changed files with 2,366 additions and 47 deletions.
47 changes: 0 additions & 47 deletions lesson_plans/20231110_overview.txt

This file was deleted.

File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes.
14 changes: 14 additions & 0 deletions lesson_plans/day_5/20231113_richel.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# Lesson plan 2023-11-12 by Richel

## Learning objectives

* Being able to use regular expression in a tested function

## Teacher goals

* Show TDD in live coding
* Students must code often

## Plan for today

* Use the existing exercises, prepare the students for those
20 changes: 20 additions & 0 deletions lesson_plans/day_5/check_python_style.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
#!/bin/bash
#
#

# Ignore the first ruff error
ruff day_3.qmd > temp_ruff_results.txt 2>&1

last_line=$(cat temp_ruff_results.txt | tail -n 1)
# echo "last_line: ${last_line}"
n_errors_plus_one=$(echo "${last_line}" | cut -d ' ' -f 2)
# echo "Number of errors plus one: ${n_errors_plus_one}"
n_errors=$((n_errors_plus_one-1))
echo "Number of errors: ${n_errors}"

exit ${n_errors}

# FAILS: will still always give an error
# Remove the part between '---'
#tail -n +11 day_3.qmd > temp_day_3.qmd
#ruff temp_day_3.qmd
Loading

0 comments on commit 80d9461

Please sign in to comment.