Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
EventGen
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
chaotikum
EventGen
Commits
41e3ff19
Commit
41e3ff19
authored
5 months ago
by
Lukas Ruge
Browse files
Options
Downloads
Patches
Plain Diff
update
parent
60756cd1
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
README.md
+1
-3
1 addition, 3 deletions
README.md
main.py
+14
-3
14 additions, 3 deletions
main.py
public-domain-movie-night.txt
+12
-0
12 additions, 0 deletions
public-domain-movie-night.txt
with
27 additions
and
6 deletions
README.md
+
1
−
3
View file @
41e3ff19
...
...
@@ -2,8 +2,6 @@
Kleines Helper-Tool. Im Grunde erstellt es Regeltermine, für den Chaotikum-Kalender.
Das sind Makrdown Dateien, das ist ohne Skript einfach anstrengend.
## Open Space
Jeden Mittwoch 19:00 to 23:59:59 aber nicht zwischen oder am 24.12 und 1.1
...
...
@@ -23,7 +21,7 @@ Quartalsweise am 3. Donnerstag im zweiten Monat des Quartals, also Februar, Mai,
Zweiter freitag im November (und der darauf folgende Samstag)
## Fünf Minuten Termine
Zweiter Mittwoch im
Jan
uar,
April
, September und Dezember
Zweiter Mittwoch im
Febr
uar,
Mai
, September und Dezember
## Somerfest
Der erste Samstag nach dem 10. Mai. 15:00 bis 23:59
...
...
This diff is collapsed.
Click to expand it.
main.py
+
14
−
3
View file @
41e3ff19
...
...
@@ -29,7 +29,7 @@ NOOK = True
# zweiter freitag im November (und der darauf folgende Samstag)
# FÜNF MINUTEN TERMINE
# Zweiter Mittwoch im Februar,
April
, september und dezember
# Zweiter Mittwoch im Februar,
Mai
, september und dezember
FUENF_MIN_TERMINE
=
True
SOMMERFEST
=
True
...
...
@@ -64,6 +64,10 @@ CTF = True
# unklar
WED_VIDEO_SETUP
=
False
# Public Domain Movie
# Zweiter Freitag im Januar
PUBLIC_DOMAIN_MOVIE
=
True
#################################################
# Year to create events for
#################################################
...
...
@@ -121,7 +125,7 @@ def is_nook(_date_candidate):
def
is_fuenf_min
(
_date_candidate
):
if
utils
.
is_february
(
_date_candidate
)
or
utils
.
is_
april
(
_date_candidate
)
or
utils
.
is_september
(
if
utils
.
is_february
(
_date_candidate
)
or
utils
.
is_
may
(
_date_candidate
)
or
utils
.
is_september
(
_date_candidate
)
or
utils
.
is_december
(
_date_candidate
):
if
utils
.
is_nth_wednesday_of_month
(
_date_candidate
,
2
):
return
True
...
...
@@ -167,7 +171,8 @@ def is_ctf(_date_candidate):
utils
.
is_days_away_from
(
_date_candidate
,
datetime
.
datetime
.
strptime
(
"
2024-07-02
"
,
utils
.
date_format
))
%
14
==
0
)
def
is_public_domain_movie_night
(
_date_candidate
):
return
utils
.
is_january
(
_date_candidate
)
and
utils
.
is_nth_friday_of_month
(
_date_candidate
,
2
);
def
create_open_space
(
_date
):
utils
.
create_event
(
"
openspace
"
,
_date
,
start_hour
=
19
)
...
...
@@ -231,6 +236,8 @@ def create_ctf(_date):
def
create_maus_tueroeffner_tag
(
_date
):
utils
.
create_event
(
"
maus
"
,
_date
,
start_hour
=
14
,
end_hour
=
19
,
end_minute
=
00
)
def
create_public_domain_movie_night
(
_date
):
utils
.
create_event
(
"
public-domain-movie-night
"
,
_date
,
start_hour
=
20
,
end_hour
=
22
,
end_minute
=
00
)
date_to_check
=
datetime
.
datetime
.
strptime
(
str
(
YEAR
)
+
"
-01-01
"
,
utils
.
date_format
)
while
date_to_check
<=
datetime
.
datetime
.
strptime
(
str
(
YEAR
)
+
"
-12-31
"
,
utils
.
date_format
):
...
...
@@ -298,5 +305,9 @@ while date_to_check <= datetime.datetime.strptime(str(YEAR) + "-12-31", utils.da
result
=
is_wed_video_setup
(
date_to_check
)
if
result
:
create_wed_video_setup
(
date_to_check
)
if
PUBLIC_DOMAIN_MOVIE
:
result
=
is_public_domain_movie_night
(
date_to_check
)
if
result
:
create_public_domain_movie_night
(
date_to_check
)
date_to_check
+=
datetime
.
timedelta
(
days
=
1
)
This diff is collapsed.
Click to expand it.
public-domain-movie-night.txt
0 → 100644
+
12
−
0
View file @
41e3ff19
---
layout: [eventcal]
title: "Public Domain Movie Night"
eventdate: <EVENTSTART>
eventend: <EVENTEND>
#https://www.uuidgenerator.net/
uid: <UUID>
organizer: Chaotikum
locations:
- Comfy Zone
short: "Lights Out. Filmabende im Nobreakspace - Es gibt Popcorn und einen gemeinfreien Film."
---
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment