Compare commits

..

No commits in common. "8d942cf2f3ae50e95e70a43273a405cb9c6ebb53" and "4bcd13a713391c67871029cda337853ddc85f51b" have entirely different histories.

20 changed files with 137 additions and 206 deletions

View File

@ -31,12 +31,9 @@ nginx -p . -s stop
## TODO: ## TODO:
- [x] create page builder - [x] create page builder
- rename `prep.py` to more informative name (`build_events.py`)
- [ ] create blogging system - [ ] create blogging system
- [ ] create xmpp bot that connects to events section. - [ ] create xmpp bot that connects to events section.
- [ ] webring system - [ ] webring system
- [x] make page - [x] make page
- [ ] populate page - [ ] populate page
- [x] make english version - [ ] make english version (localisation)
- double check spelling and wording
- add account and donations page and style them with the site style

View File

@ -5,7 +5,6 @@ PAGES = [
{'name': 'account', 'titleSR': 'Nalog', 'titleEN': 'Account', 'style': 'account'}, {'name': 'account', 'titleSR': 'Nalog', 'titleEN': 'Account', 'style': 'account'},
{'name': 'contact', 'titleSR': 'Kontakt', 'titleEN': 'Contact', 'style': 'contact'}, {'name': 'contact', 'titleSR': 'Kontakt', 'titleEN': 'Contact', 'style': 'contact'},
{'name': 'events', 'titleSR': 'Događaji', 'titleEN': 'Events', 'style': 'events'}, {'name': 'events', 'titleSR': 'Događaji', 'titleEN': 'Events', 'style': 'events'},
{'name': 'events_archive', 'titleSR': 'Arhiva događaja', 'titleEN': 'Events archive', 'style': 'events'},
{'name': 'services', 'titleSR': 'Servisi', 'titleEN': 'Services', 'style': 'services'}, {'name': 'services', 'titleSR': 'Servisi', 'titleEN': 'Services', 'style': 'services'},
{'name': 'webring', 'titleSR': 'Webring', 'titleEN': 'Webring', 'style': ''}, {'name': 'webring', 'titleSR': 'Webring', 'titleEN': 'Webring', 'style': ''},
] ]

View File

@ -1,63 +1,21 @@
datum, vreme, lokacija, tema datum, vreme, lokacija, tema
20-12-2022, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Uvod u računarske mreze, firewall 03-05-2023, 12:00, Cvijeta Zuzoric https://www.openstreetmap.org/node/256367543, Otvaranje izlozbe (Q&A)
03-01-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Hakaton žurka
16-01-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Radionica privatnosti na internetu
04-01-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Hakaton žurka
13-02-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Uvod u Bitcoin radonica
14-02-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Privacy & Security predavanje
20-02-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Cyber reconnisance radionica
21-02-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Uvod u konfiguraciju servera radionica (pomerena)
27-02-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Šta je Decentrala + hakaton
03-03-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Uvod u python
10-03-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Uvod u python
13-03-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, TLS (SSL) kriptografija
14-03-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Matrix chat protokol
20-03-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, LDAP protokol radionica
21-03-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Android reverse engineering
25-03-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Open hackerspace day - film
27-03-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, SQL baze podataka
28-03-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Esolang
03-04-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Pentest radionica
04-04-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Runtime modification of Android apps
10-04-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Hakaton
11-04-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Uvod u OpenBSD
17-04-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Lan party
18-04-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Pentest radionica nastavak
23-04-2023, 19:00, Polyhedra https://www.openstreetmap.org/node/4856556781, Uvod u mreže
03-05-2023, 12:00, Cvijeta Zuzorić https://www.openstreetmap.org/node/256367543, Otvaranje izlozbe (Q&A)
03-05-2023, 18:00, KC Grad https://www.openstreetmap.org/node/4118716889, Linux install fest 03-05-2023, 18:00, KC Grad https://www.openstreetmap.org/node/4118716889, Linux install fest
04-05-2023, 17:00, Cvijeta Zuzorić https://www.openstreetmap.org/node/256367543, ULUS izlozba (Q&A) 04-05-2023, 17:00, Cvijeta Zuzoric https://www.openstreetmap.org/node/256367543, ULUS izlozba (Q&A)
04-05-2023, 18:00, Polyhedra https://www.openstreetmap.org/node/4856556781, Uvod u racunarske mreze 04-05-2023, 18:00, Polyhedra https://www.openstreetmap.org/node/4856556781, Uvod u racunarske mreze
04-05-2023, 21:00, n/a, Online sastanak sa Zajednicom za slobodnu tehnologiju iz Kikinde 04-05-2023, 21:00, n/a, Online sastanak sa Zajednicom za slobodnu tehnologiju iz Kikinde
05-05-2023, 15:30, Cvijeta Zuzorić https://www.openstreetmap.org/node/256367543, ULUS izlozba (Q&A) 05-05-2023, 15:30, Cvijeta Zuzoric https://www.openstreetmap.org/node/256367543, ULUS izlozba (Q&A)
06-05-2023, 12:00, Cvijeta Zuzorić https://www.openstreetmap.org/node/256367543, ULUS izlozba (Q&A) 06-05-2023, 12:00, Cvijeta Zuzoric https://www.openstreetmap.org/node/256367543, ULUS izlozba (Q&A)
07-05-2023, 16:00, Cvijeta Zuzorić https://www.openstreetmap.org/node/256367543, ULUS izlozba (diskusija) 07-05-2023, 16:00, Cvijeta Zuzoric https://www.openstreetmap.org/node/256367543, ULUS izlozba (diskusija)
08-05-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Linux install day 08-05-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Linux install day
09-05-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Cryptoparty - Uvod u privatnost 09-05-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Cryptoparty - Uvod u privatnost
11-05-2023, 18:00, Polyhedra https://www.openstreetmap.org/node/4856556781, Uvod u računarske mreže 11-05-2023, 18:00, Polyhedra https://www.openstreetmap.org/node/4856556781, Uvod u racunarske mreze
05-06-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Šifre 01-08-2023, 19:00, DC Krov, Tehno veče
06-06-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Random i kriptografija 07-08-2023, 19:00, DC Krov, Linux ricing
12-06-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Uvod u Blender 08-08-2023, 19:00, DC Krov, Lambda račun
13-06-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Cybersecurity odbrana 14-08-2023, 19:00, DC Krov, Linux distro diskusija
19-06-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Pisanje BASH skripti 15-08-2023, 19:00, DC Krov, Pirati 777 mora
20-06-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Cybersecurity odbrana 21-08-2023, 19:00, DC Krov, Python vežbe
26-06-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Python vežbe 22-08-2023, 19:00, DC Krov, Autentifikacija na internetu
27-06-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Cybersecurity odbrana 28-08-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Podesavanje Mail servera
03-07-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, DNS 29-08-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Prevodjenje wiki-a
04-07-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Cybersecurity odbrana
10-07-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Blender, 3D modelovanje
11-07-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Cybersecurity odbrana
17-07-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, OpenGL
18-07-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Cybersecurity odbrana
24-07-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Web scraping
25-07-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Cybersecurity odbrana
31-07-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Python - Web development
01-08-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Tehno veče
07-08-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Linux ricing
08-08-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Lambda račun
14-08-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Linux distro diskusija
15-08-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Pirati 777 mora
21-08-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Python vežbe
22-08-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Autentifikacija na internetu
28-08-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Podešavanje Mail servera
29-08-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Prevođenje wiki-a

1 datum, vreme, lokacija, tema datum vreme lokacija tema
2 20-12-2022, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Uvod u računarske mreze, firewall 03-05-2023 12:00 Cvijeta Zuzoric https://www.openstreetmap.org/node/256367543 Otvaranje izlozbe (Q&A)
03-01-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Hakaton žurka
16-01-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Radionica privatnosti na internetu
04-01-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Hakaton žurka
13-02-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Uvod u Bitcoin radonica
14-02-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Privacy & Security predavanje
20-02-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Cyber reconnisance radionica
21-02-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Uvod u konfiguraciju servera radionica (pomerena)
27-02-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Šta je Decentrala + hakaton
03-03-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Uvod u python
10-03-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Uvod u python
13-03-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, TLS (SSL) kriptografija
14-03-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Matrix chat protokol
20-03-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, LDAP protokol radionica
21-03-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Android reverse engineering
25-03-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Open hackerspace day - film
27-03-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, SQL baze podataka
28-03-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Esolang
03-04-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Pentest radionica
04-04-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Runtime modification of Android apps
10-04-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Hakaton
11-04-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Uvod u OpenBSD
17-04-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Lan party
18-04-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Pentest radionica nastavak
23-04-2023, 19:00, Polyhedra https://www.openstreetmap.org/node/4856556781, Uvod u mreže
03-05-2023, 12:00, Cvijeta Zuzorić https://www.openstreetmap.org/node/256367543, Otvaranje izlozbe (Q&A)
3 03-05-2023, 18:00, KC Grad https://www.openstreetmap.org/node/4118716889, Linux install fest 03-05-2023 18:00 KC Grad https://www.openstreetmap.org/node/4118716889 Linux install fest
4 04-05-2023, 17:00, Cvijeta Zuzorić https://www.openstreetmap.org/node/256367543, ULUS izlozba (Q&A) 04-05-2023 17:00 Cvijeta Zuzoric https://www.openstreetmap.org/node/256367543 ULUS izlozba (Q&A)
5 04-05-2023, 18:00, Polyhedra https://www.openstreetmap.org/node/4856556781, Uvod u racunarske mreze 04-05-2023 18:00 Polyhedra https://www.openstreetmap.org/node/4856556781 Uvod u racunarske mreze
6 04-05-2023, 21:00, n/a, Online sastanak sa Zajednicom za slobodnu tehnologiju iz Kikinde 04-05-2023 21:00 n/a Online sastanak sa Zajednicom za slobodnu tehnologiju iz Kikinde
7 05-05-2023, 15:30, Cvijeta Zuzorić https://www.openstreetmap.org/node/256367543, ULUS izlozba (Q&A) 05-05-2023 15:30 Cvijeta Zuzoric https://www.openstreetmap.org/node/256367543 ULUS izlozba (Q&A)
8 06-05-2023, 12:00, Cvijeta Zuzorić https://www.openstreetmap.org/node/256367543, ULUS izlozba (Q&A) 06-05-2023 12:00 Cvijeta Zuzoric https://www.openstreetmap.org/node/256367543 ULUS izlozba (Q&A)
9 07-05-2023, 16:00, Cvijeta Zuzorić https://www.openstreetmap.org/node/256367543, ULUS izlozba (diskusija) 07-05-2023 16:00 Cvijeta Zuzoric https://www.openstreetmap.org/node/256367543 ULUS izlozba (diskusija)
10 08-05-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Linux install day 08-05-2023 19:00 DC Krov https://www.openstreetmap.org/node/10594728522 Linux install day
11 09-05-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Cryptoparty - Uvod u privatnost 09-05-2023 19:00 DC Krov https://www.openstreetmap.org/node/10594728522 Cryptoparty - Uvod u privatnost
12 11-05-2023, 18:00, Polyhedra https://www.openstreetmap.org/node/4856556781, Uvod u računarske mreže 11-05-2023 18:00 Polyhedra https://www.openstreetmap.org/node/4856556781 Uvod u racunarske mreze
13 05-06-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Šifre 01-08-2023 19:00 DC Krov Tehno veče
14 06-06-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Random i kriptografija 07-08-2023 19:00 DC Krov Linux ricing
15 12-06-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Uvod u Blender 08-08-2023 19:00 DC Krov Lambda račun
16 13-06-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Cybersecurity odbrana 14-08-2023 19:00 DC Krov Linux distro diskusija
17 19-06-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Pisanje BASH skripti 15-08-2023 19:00 DC Krov Pirati 777 mora
18 20-06-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Cybersecurity odbrana 21-08-2023 19:00 DC Krov Python vežbe
19 26-06-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Python vežbe 22-08-2023 19:00 DC Krov Autentifikacija na internetu
20 27-06-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Cybersecurity odbrana 28-08-2023 19:00 DC Krov https://www.openstreetmap.org/node/10594728522 Podesavanje Mail servera
21 03-07-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, DNS 29-08-2023 19:00 DC Krov https://www.openstreetmap.org/node/10594728522 Prevodjenje wiki-a
04-07-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Cybersecurity odbrana
10-07-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Blender, 3D modelovanje
11-07-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Cybersecurity odbrana
17-07-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, OpenGL
18-07-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Cybersecurity odbrana
24-07-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Web scraping
25-07-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Cybersecurity odbrana
31-07-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Python - Web development
01-08-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Tehno veče
07-08-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Linux ricing
08-08-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Lambda račun
14-08-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Linux distro diskusija
15-08-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Pirati 777 mora
21-08-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Python vežbe
22-08-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Autentifikacija na internetu
28-08-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Podešavanje Mail servera
29-08-2023, 19:00, DC Krov https://www.openstreetmap.org/node/10594728522, Prevođenje wiki-a

View File

@ -1,4 +1,3 @@
<h1>Account</h1>
<p>If you have created an account on dmz.rs, you can use our XMPP and e-mail server, as well as other services that support LDAP login.<p> <p>If you have created an account on dmz.rs, you can use our XMPP and e-mail server, as well as other services that support LDAP login.<p>
<p>For more on XMPP see <a href="https://wiki.dmz.rs/en/tutorial/conversations">this tutorial</a>. <p> <p>For more on XMPP see <a href="https://wiki.dmz.rs/en/tutorial/conversations">this tutorial</a>. <p>
<p>You can see settings for the <a href="https://thunderbird.org">Thundebird</a> mail client on this <a href="/img/mailsettings.png">image</a>.<p> <p>You can see settings for the <a href="https://thunderbird.org">Thundebird</a> mail client on this <a href="/img/mailsettings.png">image</a>.<p>

View File

@ -1,2 +1 @@
<h1>Events</h1> <h1>Events</h1>
<p>Following list contains all forthcoming events. Held events are listed in <a href="/en/events_archive">archive</a></p>

View File

@ -1,2 +0,0 @@
<h1>Events archive</h1>
<p>All events that we organized so far.</p><br>

View File

@ -49,6 +49,6 @@
<p> <p>
These are some of the services we currently maintain on our servers. These are some of the services we currently maintain on our servers.
To use these services, you can register for each service separately, To use these services, you can register for each service separately,
or you can create a unique <a href="/en/account">account</a> or you can create a unique <a href="/pages/account.html">account</a>
on our server and use all services with the same account. on our server and use all services with the same account.
</p> </p>

View File

@ -1,4 +1,3 @@
<h1>Webring</h1>
<ul> <ul>
<li><a href="https://tilde.zone/explore">Tilde Zone</a></li> <li><a href="https://tilde.zone/explore">Tilde Zone</a></li>
</ul> </ul>

View File

@ -1,4 +1,3 @@
<h1>Nalog</h1>
<p>Ako si napravio nalog na dmz.rs možeš koristiti naš XMPP i e-mail server, kao i ostale servise koji podržavaju LDAP login.<p> <p>Ako si napravio nalog na dmz.rs možeš koristiti naš XMPP i e-mail server, kao i ostale servise koji podržavaju LDAP login.<p>
<p>Za više o XMPP-u pogledaj <a href="https://wiki.dmz.rs/en/tutorial/conversations">tutorial</a>. <p> <p>Za više o XMPP-u pogledaj <a href="https://wiki.dmz.rs/en/tutorial/conversations">tutorial</a>. <p>
<p>Podešavanja za <a href="https://thunderbird.org">Thundebird</a> mail klijent možeš pogledati na <a href="/img/mailsettings.png">slici</a>.<p> <p>Podešavanja za <a href="https://thunderbird.org">Thundebird</a> mail klijent možeš pogledati na <a href="/img/mailsettings.png">slici</a>.<p>

View File

@ -1,2 +1 @@
<h1>Događaji</h1> <h1>Događaji</h1>
<p>Naredna lista sadrži sve predstojeće događaje. Za listu održanih događaja pogledajte <a href="/events_archive">arhivu</a></p>

View File

@ -1,2 +0,0 @@
<h1>Arhiva događaja</h1>
<p>Svi događaji koje smo do sada organzivali.</p><br>

View File

@ -54,5 +54,5 @@
</tr> </tr>
</table> </table>
<p>Ovo su neki od servisa koje trenutno održavamo na našim serverima. Da bi koristio ove servise, <em>možeš</em> da se <p>Ovo su neki od servisa koje trenutno održavamo na našim serverima. Da bi koristio ove servise, <em>možeš</em> da se
registuješ na svaki servis posebno, a možeš i da napraviš jedinstveni <a href="/account">nalog</a> na našem registuješ na svaki servis posebno, a možeš i da napraviš jedinstveni <a href="/pages/account.html">nalog</a> na našem
serveru i da koristiš sve servise sa istim nalogom.</p> serveru i da koristiš sve servise sa istim nalogom.</p>

View File

@ -1,4 +1,3 @@
<h1>Webring</h1>
<ul> <ul>
<li><a href="https://tilde.zone/explore">Tilde Zone</a></li> <li><a href="https://tilde.zone/explore">Tilde Zone</a></li>
</ul> </ul>

152
prep.py
View File

@ -1,88 +1,92 @@
#! /usr/bin/env python #! /usr/bin/env python
import csv
from datetime import datetime from datetime import datetime
from functools import cmp_to_key
DAYS_SR = ["PON", "UTO", "SRE", "ČET", "PET", "SUB", "NED"] DAYS_SR = ["Ponedeljak", "Utorak", "Sreda", "Četvrtak", "Petak", "Subota", "Nedelja"]
DAYS_EN = ["MON ", "TUE", "WED", "THU", "FRI", "SAT", "SUN"] DAYS_EN = ["Monday ", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday", "Sunday"]
MONTHS_SR = [
def load_events(csv_path:str) -> list[dict]: "Januar", "Februar", "Mart", "April", "Maj", "Jun",
events = [] "Jul", "Avgust", "Septembar", "Oktobar", "Novembar", "Decembar",
with open(csv_path) as csv_file: ]
csv_reader = csv.reader(csv_file) MONTHS_EN = [
next(csv_reader, None) "January", "February", "March", "April", "May", "June",
for event in csv_reader: "July", "August", "September", "October", "November", "December",
event_date = event[0] ]
event_date_parsed = datetime.strptime(event_date, "%d-%m-%Y").date()
event_time = event[1]
event_location = event[2]
event_title = event[3]
current_event = {"date":event_date_parsed,
"time":event_time,
"location": event_location,
"title":event_title.strip()}
events.append(current_event)
return events
def build_html(events: list[dict], dayNames: list[str]) -> str:
events_html = []
for event in events:
title = event["title"]
location = event["location"]
date = event["date"]
date = dayNames[date.weekday()]+", "+str(date.day)+". "+str(date.month)+". "+str(date.year)+", "
time = event["time"]+"h"
event_html = []
event_html.append(f"<div class='date'>{date} {time}</div>")
event_html.append(f"<div class='title'>{title}</div>")
if "https://" in location:
place,link = location.split("https://")
event_html.append(f"<div class='place'><a href=\"https://{link}\">@{place.strip()}</a></div>")
else:
event_html.append(f"<div class='place'>@{location.strip()}</div>")
event_html = "".join(event_html)
events_html.append(f"\n<div class='event'>{event_html}</div>")
return events_html
events = sorted(load_events("dogadjaji.csv"), key=lambda e: e["date"])
today = datetime.today().date() today = datetime.today().date()
past_events = list(filter(lambda e: e["date"] <= today, events)) def parse_date(date):
new_events = list(filter(lambda e: e["date"] >= today, events)) return datetime.strptime(date,"%d-%m-%Y").date()
def compare_events(one, two):
one = parse_date(one.split(", ")[0])
two = parse_date(two.split(", ")[0])
if one>two:
return 1
elif one==two:
return 0
else:
return -1
def is_past_event(event):
return event < today
def load_events():
events = []
with open("dogadjaji.csv", "rt") as file:
file.readline()
for event in file.readlines():
event = event.strip()
if event != "":
events.append(event)
return events
def write_events(events):
with open("dogadjaji.csv", "wt") as file:
file.write("datum, vreme, lokacija, tema\n")
for event in events:
file.write(event+"\n")
def sort_events(events):
return sorted(events, key = cmp_to_key(compare_events))
page_template = "" def build_html(events, dayNames, monthNames):
newevents = []
for event in events:
date, time, location, title = event.split(", ")
date = parse_date(date)
if is_past_event(date):
continue
date = dayNames[date.weekday()]+", "+str(date.day)+". "+monthNames[date.month-1]+" "+str(date.year)+"."
time = time+"h"
future_event = []
future_event.append("<td> "+date+" </td>")
future_event.append("<td> "+time+" </td>")
if "https://" in location:
place,link = location.split("https://")
future_event.append("<td> <a href=\"https://"+link+"\""+"> "+place.strip()+" </a> </td>")
else:
future_event.append("<td> "+location.strip()+" </td>")
future_event.append("<td> "+title+" </td>")
newevents.append("<tr>\n"+"\n".join(future_event)+"\n</tr>")
return newevents
# Build Serbian Events page events = load_events()
new_events_html = build_html(new_events, DAYS_SR) events = sort_events(events)
with open("pages/sr/events.html", "r") as file: write_events(events)
page_template = ([line for line in file])[:2]
with open("pages/sr/events.html", "w") as file: newevents = build_html(events, DAYS_SR, MONTHS_SR)
file.writelines(page_template + new_events_html)
# Build English Events page with open("pages/sr/events.html","wt") as file:
new_events_html = build_html(new_events, DAYS_EN) file.writelines(["<h1>Događaji</h1>\n", "<table>\n", "<tr><th>Datum</th><th>Vreme</th><th>Mesto</th><th>Tema</th></tr>\n"])
with open("pages/en/events.html", "r") as file: file.writelines(newevents)
page_template = ([line for line in file])[:2] file.writelines(["</table>"])
with open("pages/en/events.html", "w") as file: newevents = build_html(events, DAYS_EN, MONTHS_EN)
file.writelines(page_template + new_events_html)
# Build Serbian Archive page with open("pages/en/events.html","wt") as file:
past_events_html = build_html(past_events, DAYS_SR) file.writelines(["<h1>Events</h1>\n", "<table>\n", "<tr><th>Date</th><th>Time</th><th>Place</th><th>Topic</th></tr>"])
with open("pages/sr/events_archive.html", "r") as file: file.writelines(newevents)
page_template = ([line for line in file])[:2] file.writelines(["</table>"])
with open("pages/sr/events_archive.html", "w") as file:
file.writelines(page_template + past_events_html)
# Build English Archive page
past_events_html = build_html(past_events, DAYS_EN)
with open("pages/en/events_archive.html", "r") as file:
page_template = ([line for line in file])[:2]
with open("pages/en/events_archive.html", "w") as file:
file.writelines(page_template + past_events_html)

View File

@ -0,0 +1,4 @@
h1 {
margin-bottom: 2rem;
font-weight: normal;
}

View File

@ -0,0 +1,4 @@
h1 {
margin-bottom: 2rem;
font-weight: normal;
}

View File

@ -1,58 +1,30 @@
.event { table {
display: flex; table-layout: fixed;
flex-direction: row; border-spacing: 0;
} }
.event:hover { th,
border-bottom: 5px var(--hightlight) solid; td {
} padding: 0 1rem 0 1rem;
text-align: left;
.event:hover>div {
padding-bottom: calc(0.5rem - 5px);
}
.event>div {
padding: 0.5rem;
white-space: nowrap;
}
.date {
width: 250px;
font-size: 0.9em;
overflow-x: hidden;
white-space: nowrap;
}
.title {
border-left: 2px solid var(--border); border-left: 2px solid var(--border);
font-weight: bold;
} }
.place { th {
font-size: 0.9em; padding: 1rem 1rem 0 1rem;
border-bottom: 2px solid var(--border);
} }
@media screen and (max-width: 1160px) { td:nth-child(odd) {
.event { white-space: nowrap;
flex-direction: column; }
margin-bottom: 1rem;
border-left: 2px solid var(--border); td {
} padding: 0 1rem 1rem 1rem;
vertical-align: top;
.event > div { }
padding: 0 0.5rem;
white-space: normal; h1 {
} margin-bottom: 2rem;
font-weight: normal;
.event:hover {
border-bottom: none;
}
.event:hover> div {
padding-bottom: 0;
}
.title {
border-left: none;
}
} }

View File

@ -1,3 +1,8 @@
h1 {
margin-bottom: 2rem;
font-weight: normal;
}
dl { dl {
padding: 1rem 0; padding: 1rem 0;
} }

View File

@ -20,3 +20,8 @@ td {
padding: 0 1rem 1rem 1rem; padding: 0 1rem 1rem 1rem;
vertical-align: top; vertical-align: top;
} }
h1 {
margin-bottom: 2rem;
font-weight: normal;
}

View File

@ -68,13 +68,6 @@ main {
overflow: auto; overflow: auto;
} }
main h1 {
margin-bottom: 2rem;
font-weight: normal;
font-size: 1.5em;
font-variant-caps: small-caps;
}
a, a,
a:visited { a:visited {
text-decoration: none; text-decoration: none;