update
This commit is contained in:
commit
1d332c6c3c
18 changed files with 650 additions and 2 deletions
3
.gitignore
vendored
3
.gitignore
vendored
|
@ -1,3 +1,4 @@
|
|||
logseq/bak/
|
||||
logseq/.recycle
|
||||
|
||||
logseq/pages-metadata.edn
|
||||
**/*.edn
|
||||
|
|
11
journals/2022_10_12.md
Normal file
11
journals/2022_10_12.md
Normal file
|
@ -0,0 +1,11 @@
|
|||
- Hacker's garage
|
||||
- Dis
|
||||
- Ripasso moti del piano
|
||||
- Definizione di velocità e accelerazione
|
||||
- Semplici conversioni tra km/h e m/s
|
||||
- Unità di misura dell'accelerazione (perché m/s²)
|
||||
- Grafici velocità-tempo e posizione-tempo
|
||||
- Tipi di relazione tra grandezze fisiche
|
||||
- Relazioni dirette e inverse
|
||||
- Caduta dei gravi
|
||||
- Valore dell'accelerazione di gravità
|
6
journals/2022_10_17.md
Normal file
6
journals/2022_10_17.md
Normal file
|
@ -0,0 +1,6 @@
|
|||
- Non ci sarà il collegio del 26.10
|
||||
- Il PNRR ha diverse linee di finanziamento
|
||||
- Il 13.8% degli studenti della nostra scuola è ad un livello insufficiente sia in Italiano che in Matematica
|
||||
- Scuola 4.0
|
||||
- La classe
|
||||
- Laboratori
|
4
journals/2022_10_19.md
Normal file
4
journals/2022_10_19.md
Normal file
|
@ -0,0 +1,4 @@
|
|||
- Per ridurre le dimensioni di un PDF contenente immagini #bash
|
||||
- ```bash
|
||||
ps2pdf input.pdf output.pdf
|
||||
```
|
6
journals/2022_10_22.md
Normal file
6
journals/2022_10_22.md
Normal file
|
@ -0,0 +1,6 @@
|
|||
- Per configurare #wireguard su #libreelec #kodi
|
||||
- https://wiki.libreelec.tv/configuration/wireguard
|
||||
- Nextcloud 25 non funziona su Rasbperry OS 32 bit #raspberry
|
||||
- https://help.nextcloud.com/t/no-file-structure-displayed-after-updating-to-25-0-0rc2/146784/7
|
||||
- Come funziona il transcoding #ffmpeg #htpc
|
||||
- https://www.reddit.com/r/jellyfin/comments/mfaf6h/please_help_me_understand_how_transcoding_works/
|
4
journals/2022_10_24.md
Normal file
4
journals/2022_10_24.md
Normal file
|
@ -0,0 +1,4 @@
|
|||
- Buongiorno Carla,
|
||||
- ecco qui i documenti che mi hai richiesto. Ho articolato il corso in 13 lezioni: 12 lezioni da 3 ore e 1 da 4 ore. Per favore, mi diresti com'è distribuita l'articolazione oraria quotidiana dell'Accademia? In questo modo potrò iniziare a pensare ad un calendario di massima.
|
||||
- Grazie e a presto,
|
||||
Andrea
|
4
journals/2022_10_31.md
Normal file
4
journals/2022_10_31.md
Normal file
|
@ -0,0 +1,4 @@
|
|||
- Per trovare gli IP dei device connessi ad una subnet #bash
|
||||
- ```bash
|
||||
sudo nmap -sn 192.168.1.0/24
|
||||
```
|
1
journals/2022_11_07.md
Normal file
1
journals/2022_11_07.md
Normal file
|
@ -0,0 +1 @@
|
|||
- Si presenteranno le esperienze maturate nell'ambito della valutazione, soprattutto durante il periodo di DAD, imperniate su tecniche di microvalutazione mediate da strumenti digitali. Verranno discusse le tecnologie informatiche utilizzate per la produzione e la somministrazione di verifiche strutturate e semistrutturate, per la loro valutazione e per la generazione di dati statistici utilizzabili allo scopo di personalizzare gli apprendimenti degli studenti. Verrà discusso il prototipo di una piattaforma open source in costruzione all'interno del Liceo Carducci Dante di Trieste, pensata per le scuole in sostituzione o a supporto di piattaforme di terze parti proprietarie (Kahoot, Google Moduli, etc).
|
4
journals/2022_11_11.md
Normal file
4
journals/2022_11_11.md
Normal file
|
@ -0,0 +1,4 @@
|
|||
- Per configurare un locale #bash #mosh
|
||||
- ```bash
|
||||
sudo locale-gen de_DE.UTF-8
|
||||
```
|
1
journals/2022_11_15.md
Normal file
1
journals/2022_11_15.md
Normal file
|
@ -0,0 +1 @@
|
|||
- Candy Box #mustcheck
|
14
journals/2022_11_16.md
Normal file
14
journals/2022_11_16.md
Normal file
|
@ -0,0 +1,14 @@
|
|||
- Quick start per #kratos
|
||||
- Il server espone la porta 4433 che risponde un'API pubblica per la gestione delle'autenticazione/autorizzazione
|
||||
- Il server espone la porta 4434 che risponde ad un'API privata per l'amministratore
|
||||
- Documentazione approfondita per i [flussi](https://www.ory.sh/docs/kratos/self-service)
|
||||
- Repository [client-go](https://github.com/ory/kratos-client-go)
|
||||
- [Esempio](https://github.com/davidoram/kratos-selfservice-ui-go/blob/main/handlers/login.go) di self-service UI in Go
|
||||
- Passi
|
||||
- Ottenere un flow
|
||||
- ```bash
|
||||
curl http://localhost:4433/self-service/login/browser
|
||||
```
|
||||
- Kratos reindirizza il browser su un URL definito nel file di configurazione kratos.yml e aggiunge il parametro query `flow`
|
||||
- Avanzare una richiesta contenente il `flow`
|
||||
-
|
4
journals/2022_11_17.md
Normal file
4
journals/2022_11_17.md
Normal file
|
@ -0,0 +1,4 @@
|
|||
- Henri Bergson: «Pensa come uomo d'azione e agisci da uomo di pensiero»
|
||||
- Che ama lo sviluppo ama la libertà
|
||||
- I giovani oggi sono più tristi perché consumano troppi beni materiali
|
||||
- Morti per disperazione
|
4
journals/2022_11_19.md
Normal file
4
journals/2022_11_19.md
Normal file
|
@ -0,0 +1,4 @@
|
|||
- Contatti raccolti per #Probo
|
||||
- rosannadelvecchio@istitutosuperioregentileschi.it
|
||||
- cosimina.ligorio@liceobianchidottula.it
|
||||
- rossana.maragioglio@gmail.com
|
1
journals/2022_11_20.md
Normal file
1
journals/2022_11_20.md
Normal file
|
@ -0,0 +1 @@
|
|||
- Questionario bisogni scuole #impresa
|
1
journals/2022_11_21.md
Normal file
1
journals/2022_11_21.md
Normal file
|
@ -0,0 +1 @@
|
|||
- Si, credo di capire. Io ho un giardino immaginario, il mio giardino, che con grande spaccamento di maroni cerco di tenere in ordine e pulito. Capita di farci qualche festa dentro e di lasciare un porcile. Però è la mia festa ed è il mio porcile. M'è successo un paio di volte - l'ultima è recente - che qualcuna che prima aveva le chiavi ci entrasse dentro scavalcando il cancello, ovviamente senza suonare. Ed è capitato che l'intrusa si divertisse pure a calpestare l'erba e a farsi un bagno in piscina. Ora, la psicoterapia, il counseling, lo zen e l'amore universale mi insegnano che tutti combattono la loro battaglia. Ma da un po' di tempo a questa parte invito le persone non desiderate a combatterla fuori dai coglioni. E poi che dire del vuoto: a volte bisogna veramente crearselo intorno e goderselo. Che un certo tipo di vuoto in realtà vuoto non è: contiene già i semi di piante nuove. Infatti qualcuno lo chiama vuoto fertile. #scrittura
|
|
@ -165,7 +165,7 @@
|
|||
:ref/default-open-blocks-level 2
|
||||
|
||||
:ref/linked-references-collapsed-threshold 50
|
||||
:graph/settings {:orphan-pages? false, :builtin-pages? false, :journal? false}
|
||||
:graph/settings {:orphan-pages? false, :builtin-pages? false, :journal? true}
|
||||
:favorites []
|
||||
:journal/page-title-format "E, dd.MM.yyyy"
|
||||
:mobile/toolbar-stats {:bold {:counts 0}, :brand-youtube {:counts 1}, :checkbox {:counts 0}, :parentheses {:counts 0}, :command {:counts 0}, :calendar {:counts 0}, :paint {:counts 1}, :list {:counts 0}, :link {:counts 0}, :strikethrough {:counts 0}, :code {:counts 0}, :camera {:counts 0}, :rotate {:counts 0}, :tag {:counts 0}, :brackets {:counts 0}, :italic {:counts 0}, :a-b {:counts 0}, :rotate-clockwise {:counts 0}}
|
||||
|
|
|
@ -50,8 +50,13 @@
|
|||
:block/created-at 1645528617367,
|
||||
:block/updated-at 1645528617367}
|
||||
{:block/name "class",
|
||||
<<<<<<< HEAD
|
||||
:block/created-at 1663845532928,
|
||||
:block/updated-at 1663845532928}
|
||||
=======
|
||||
:block/created-at 1668152029876,
|
||||
:block/updated-at 1668152029876}
|
||||
>>>>>>> 171aabfa957c7f3a81be83ded715c04b953b7bc5
|
||||
{:block/name "classiseconde",
|
||||
:block/created-at 1654705601431,
|
||||
:block/updated-at 1654705601431}
|
||||
|
@ -65,8 +70,13 @@
|
|||
:block/created-at 1656695849531,
|
||||
:block/updated-at 1656695849531}
|
||||
{:block/name "color",
|
||||
<<<<<<< HEAD
|
||||
:block/created-at 1663845533176,
|
||||
:block/updated-at 1663845533176}
|
||||
=======
|
||||
:block/created-at 1668152030172,
|
||||
:block/updated-at 1668152030172}
|
||||
>>>>>>> 171aabfa957c7f3a81be83ded715c04b953b7bc5
|
||||
{:block/name "configurazione di un mailserver self-hosted",
|
||||
:block/created-at 1654158097389,
|
||||
:block/updated-at 1654158097389}
|
||||
|
@ -97,6 +107,7 @@
|
|||
{:block/name "favorites",
|
||||
:block/created-at 1645528617364,
|
||||
:block/updated-at 1645528617364}
|
||||
<<<<<<< HEAD
|
||||
<<<<<<< HEAD
|
||||
{:block/name "fri, 01.07.2022",
|
||||
:block/created-at 1663845532455,
|
||||
|
@ -123,16 +134,48 @@
|
|||
{:block/name "feb 14th, 2022",
|
||||
:block/created-at 1662460827701,
|
||||
:block/updated-at 1662460827701}
|
||||
=======
|
||||
{:block/name "ffmpeg",
|
||||
:block/created-at 1668096142838,
|
||||
:block/updated-at 1668152028677}
|
||||
{:block/name "fri, 01.07.2022",
|
||||
:block/created-at 1668152029348,
|
||||
:block/updated-at 1668152029348}
|
||||
{:block/name "fri, 06.05.2022",
|
||||
:block/created-at 1668152030422,
|
||||
:block/updated-at 1668152030422}
|
||||
>>>>>>> 171aabfa957c7f3a81be83ded715c04b953b7bc5
|
||||
{:block/name "fri, 07.10.2022",
|
||||
:block/created-at 1665137352123,
|
||||
:block/updated-at 1665166019186}
|
||||
{:block/name "fri, 08.07.2022",
|
||||
:block/created-at 1668152029244,
|
||||
:block/updated-at 1668152029244}
|
||||
{:block/name "fri, 11.11.2022",
|
||||
:block/created-at 1668142329060,
|
||||
:block/updated-at 1668158909680}
|
||||
{:block/name "fri, 13.05.2022",
|
||||
:block/created-at 1668152030314,
|
||||
:block/updated-at 1668152030314}
|
||||
{:block/name "fri, 16.09.2022",
|
||||
:block/created-at 1663569715219,
|
||||
:block/updated-at 1663569715219}
|
||||
<<<<<<< HEAD
|
||||
{:block/name "fri, 23.09.2022",
|
||||
:block/created-at 1663916934435,
|
||||
:block/updated-at 1663916934435}
|
||||
>>>>>>> ec465b2eb07b2d5c554b6034394308363b1c1365
|
||||
=======
|
||||
{:block/name "fri, 20.05.2022",
|
||||
:block/created-at 1668152030099,
|
||||
:block/updated-at 1668152030099}
|
||||
{:block/name "fri, 27.05.2022",
|
||||
:block/created-at 1668152029986,
|
||||
:block/updated-at 1668152029986}
|
||||
{:block/name "fri, 29.04.2022",
|
||||
:block/created-at 1668152030506,
|
||||
:block/updated-at 1668152030506}
|
||||
>>>>>>> 171aabfa957c7f3a81be83ded715c04b953b7bc5
|
||||
{:block/name "frontend per collettore probo",
|
||||
:block/created-at 1658498329560,
|
||||
:block/updated-at 1658498329560}
|
||||
|
@ -160,6 +203,9 @@
|
|||
{:block/name "html",
|
||||
:block/created-at 1656570031635,
|
||||
:block/updated-at 1656570031635}
|
||||
{:block/name "htpc",
|
||||
:block/created-at 1668096142836,
|
||||
:block/updated-at 1668152028674}
|
||||
{:block/name "http",
|
||||
:block/created-at 1654327113620,
|
||||
:block/updated-at 1654327113620}
|
||||
|
@ -169,6 +215,9 @@
|
|||
{:block/name "imagemagick",
|
||||
:block/created-at 1655363874724,
|
||||
:block/updated-at 1655363874724}
|
||||
{:block/name "impresa",
|
||||
:block/created-at 1669014697652,
|
||||
:block/updated-at 1669014697652}
|
||||
{:block/name "in-progress",
|
||||
:block/created-at 1645528617371,
|
||||
:block/updated-at 1645528617371}
|
||||
|
@ -184,9 +233,21 @@
|
|||
{:block/name "json",
|
||||
:block/created-at 1645528617367,
|
||||
:block/updated-at 1645528617367}
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
{:block/name "kodi",
|
||||
:block/created-at 1668096142829,
|
||||
:block/updated-at 1668152028665}
|
||||
{:block/name "kratos",
|
||||
:block/created-at 1669014697489,
|
||||
:block/updated-at 1669014697489}
|
||||
>>>>>>> 171aabfa957c7f3a81be83ded715c04b953b7bc5
|
||||
{:block/name "later",
|
||||
:block/created-at 1645528617368,
|
||||
:block/updated-at 1645528617368}
|
||||
{:block/name "libreelec",
|
||||
:block/created-at 1668096142830,
|
||||
:block/updated-at 1668152028667}
|
||||
{:block/name "libreoffice writer",
|
||||
:block/created-at 1652882923215,
|
||||
:block/updated-at 1652882923215}
|
||||
|
@ -202,6 +263,7 @@
|
|||
{:block/name "microsoft word",
|
||||
:block/created-at 1652882913283,
|
||||
:block/updated-at 1652882913283}
|
||||
<<<<<<< HEAD
|
||||
<<<<<<< HEAD
|
||||
{:block/name "mon, 02.05.2022",
|
||||
:block/created-at 1663845533435,
|
||||
|
@ -237,16 +299,75 @@
|
|||
:block/created-at 1663845532946,
|
||||
:block/updated-at 1663845532946}
|
||||
=======
|
||||
=======
|
||||
{:block/name "mon, 02.05.2022",
|
||||
:block/created-at 1668152030484,
|
||||
:block/updated-at 1668152030484}
|
||||
{:block/name "mon, 07.11.2022",
|
||||
:block/created-at 1668096142927,
|
||||
:block/updated-at 1668151081970}
|
||||
{:block/name "mon, 09.05.2022",
|
||||
:block/created-at 1668152030398,
|
||||
:block/updated-at 1668152030398}
|
||||
{:block/name "mon, 11.07.2022",
|
||||
:block/created-at 1668152029164,
|
||||
:block/updated-at 1668152029164}
|
||||
{:block/name "mon, 13.06.2022",
|
||||
:block/created-at 1668152029720,
|
||||
:block/updated-at 1668152029720}
|
||||
{:block/name "mon, 14.02.2022",
|
||||
:block/created-at 1668152030519,
|
||||
:block/updated-at 1668152030519}
|
||||
{:block/name "mon, 16.05.2022",
|
||||
:block/created-at 1668152030240,
|
||||
:block/updated-at 1668152030240}
|
||||
{:block/name "mon, 17.10.2022",
|
||||
:block/created-at 1668096142759,
|
||||
:block/updated-at 1668152028736}
|
||||
>>>>>>> 171aabfa957c7f3a81be83ded715c04b953b7bc5
|
||||
{:block/name "mon, 19.09.2022",
|
||||
:block/created-at 1663569714778,
|
||||
:block/updated-at 1663574308529}
|
||||
{:block/name "mon, 20.06.2022",
|
||||
:block/created-at 1668152029646,
|
||||
:block/updated-at 1668152029646}
|
||||
{:block/name "mon, 21.11.2022",
|
||||
:block/created-at 1669014697681,
|
||||
:block/updated-at 1669014697681}
|
||||
{:block/name "mon, 23.05.2022",
|
||||
:block/created-at 1668152030085,
|
||||
:block/updated-at 1668152030085}
|
||||
{:block/name "mon, 24.01.2022",
|
||||
:block/created-at 1668152030524,
|
||||
:block/updated-at 1668152030524}
|
||||
{:block/name "mon, 24.10.2022",
|
||||
:block/created-at 1668096142881,
|
||||
:block/updated-at 1668152028638}
|
||||
{:block/name "mon, 26.09.2022",
|
||||
:block/created-at 1664163333330,
|
||||
:block/updated-at 1664210481100}
|
||||
<<<<<<< HEAD
|
||||
>>>>>>> ec465b2eb07b2d5c554b6034394308363b1c1365
|
||||
=======
|
||||
{:block/name "mon, 27.06.2022",
|
||||
:block/created-at 1668152029501,
|
||||
:block/updated-at 1668152029501}
|
||||
{:block/name "mon, 30.05.2022",
|
||||
:block/created-at 1668152029912,
|
||||
:block/updated-at 1668152029912}
|
||||
{:block/name "mon, 31.10.2022",
|
||||
:block/created-at 1668096142907,
|
||||
:block/updated-at 1668152028607}
|
||||
{:block/name "mosh",
|
||||
:block/created-at 1668158895151,
|
||||
:block/updated-at 1668158895151}
|
||||
>>>>>>> 171aabfa957c7f3a81be83ded715c04b953b7bc5
|
||||
{:block/name "mp4",
|
||||
:block/created-at 1655632402106,
|
||||
:block/updated-at 1655632402106}
|
||||
{:block/name "mustcheck",
|
||||
:block/created-at 1668503155006,
|
||||
:block/updated-at 1668503155006}
|
||||
{:block/name "new page: studio",
|
||||
:block/created-at 1658498330549,
|
||||
:block/updated-at 1658498330549}
|
||||
|
@ -299,14 +420,22 @@
|
|||
:block/created-at 1658498329561,
|
||||
:block/updated-at 1658498329561}
|
||||
{:block/name "probo-quiz-uuid",
|
||||
<<<<<<< HEAD
|
||||
:block/created-at 1663845532988,
|
||||
:block/updated-at 1663845532988}
|
||||
=======
|
||||
:block/created-at 1668152029975,
|
||||
:block/updated-at 1668152029975}
|
||||
>>>>>>> 171aabfa957c7f3a81be83ded715c04b953b7bc5
|
||||
{:block/name "prompt-engineering",
|
||||
:block/created-at 1662479508427,
|
||||
:block/updated-at 1662479508427}
|
||||
{:block/name "queries",
|
||||
:block/created-at 1658498330173,
|
||||
:block/updated-at 1658498330173}
|
||||
{:block/name "raspberry",
|
||||
:block/created-at 1668096142834,
|
||||
:block/updated-at 1668152028671}
|
||||
{:block/name "readme",
|
||||
:block/created-at 1662460827860,
|
||||
:block/updated-at 1662460827860}
|
||||
|
@ -325,6 +454,7 @@
|
|||
{:block/name "sandbox",
|
||||
:block/created-at 1658498330230,
|
||||
:block/updated-at 1658498330230}
|
||||
<<<<<<< HEAD
|
||||
<<<<<<< HEAD
|
||||
{:block/name "sandbox-status-id",
|
||||
:block/created-at 1663845533826,
|
||||
|
@ -346,9 +476,35 @@
|
|||
:block/created-at 1664023167326,
|
||||
:block/updated-at 1664023167326}
|
||||
>>>>>>> ec465b2eb07b2d5c554b6034394308363b1c1365
|
||||
=======
|
||||
{:block/name "sandbox-status-id",
|
||||
:block/created-at 1668152031945,
|
||||
:block/updated-at 1668152031945}
|
||||
{:block/name "sat, 04.06.2022",
|
||||
:block/created-at 1668152029796,
|
||||
:block/updated-at 1668152029796}
|
||||
{:block/name "sat, 07.05.2022",
|
||||
:block/created-at 1668152030416,
|
||||
:block/updated-at 1668152030416}
|
||||
{:block/name "sat, 19.11.2022",
|
||||
:block/created-at 1669014697631,
|
||||
:block/updated-at 1669014706531}
|
||||
{:block/name "sat, 22.10.2022",
|
||||
:block/created-at 1668096142840,
|
||||
:block/updated-at 1668152028681}
|
||||
{:block/name "sat, 25.06.2022",
|
||||
:block/created-at 1668152029539,
|
||||
:block/updated-at 1668152029539}
|
||||
{:block/name "score",
|
||||
:block/created-at 1668152029892,
|
||||
:block/updated-at 1668152029892}
|
||||
>>>>>>> 171aabfa957c7f3a81be83ded715c04b953b7bc5
|
||||
{:block/name "scratch",
|
||||
:block/created-at 1652858740880,
|
||||
:block/updated-at 1652858740880}
|
||||
{:block/name "scrittura",
|
||||
:block/created-at 1669014697680,
|
||||
:block/updated-at 1669014697680}
|
||||
{:block/name "scuola",
|
||||
:block/created-at 1656695847516,
|
||||
:block/updated-at 1656695847516}
|
||||
|
@ -368,6 +524,7 @@
|
|||
:block/created-at 1657473612381,
|
||||
:block/updated-at 1657473612381}
|
||||
{:block/name "student",
|
||||
<<<<<<< HEAD
|
||||
:block/created-at 1663845532940,
|
||||
:block/updated-at 1663845532940}
|
||||
{:block/name "studio di funzione",
|
||||
|
@ -397,6 +554,34 @@
|
|||
:block/created-at 1664124254825,
|
||||
:block/updated-at 1664124254825}
|
||||
>>>>>>> ec465b2eb07b2d5c554b6034394308363b1c1365
|
||||
=======
|
||||
:block/created-at 1668152029890,
|
||||
:block/updated-at 1668152029890}
|
||||
{:block/name "studio di funzione",
|
||||
:block/created-at 1653635111208,
|
||||
:block/updated-at 1653635111208}
|
||||
{:block/name "sun, 05.06.2022",
|
||||
:block/created-at 1668152029784,
|
||||
:block/updated-at 1668152029784}
|
||||
{:block/name "sun, 07.08.2022",
|
||||
:block/created-at 1668152028986,
|
||||
:block/updated-at 1668152028986}
|
||||
{:block/name "sun, 10.07.2022",
|
||||
:block/created-at 1668152029226,
|
||||
:block/updated-at 1668152029226}
|
||||
{:block/name "sun, 19.06.2022",
|
||||
:block/created-at 1668152029666,
|
||||
:block/updated-at 1668152029666}
|
||||
{:block/name "sun, 20.11.2022",
|
||||
:block/created-at 1669014697654,
|
||||
:block/updated-at 1669014697654}
|
||||
{:block/name "sun, 23.01.2022",
|
||||
:block/created-at 1668152030533,
|
||||
:block/updated-at 1668152030533}
|
||||
{:block/name "sun, 26.06.2022",
|
||||
:block/created-at 1668152029519,
|
||||
:block/updated-at 1668152029519}
|
||||
>>>>>>> 171aabfa957c7f3a81be83ded715c04b953b7bc5
|
||||
{:block/name "svelte",
|
||||
:block/created-at 1645528617368,
|
||||
:block/updated-at 1645528617368}
|
||||
|
@ -419,6 +604,7 @@
|
|||
:block/created-at 1658498330270,
|
||||
:block/updated-at 1658498330270}
|
||||
{:block/name "thu, 02.06.2022",
|
||||
<<<<<<< HEAD
|
||||
:block/created-at 1663845532875,
|
||||
:block/updated-at 1663845532875}
|
||||
{:block/name "thu, 05.05.2022",
|
||||
|
@ -454,10 +640,42 @@
|
|||
:block/created-at 1663816933863,
|
||||
:block/updated-at 1663816933863}
|
||||
>>>>>>> ec465b2eb07b2d5c554b6034394308363b1c1365
|
||||
=======
|
||||
:block/created-at 1668152029811,
|
||||
:block/updated-at 1668152029811}
|
||||
{:block/name "thu, 05.05.2022",
|
||||
:block/created-at 1668152030449,
|
||||
:block/updated-at 1668152030449}
|
||||
{:block/name "thu, 07.07.2022",
|
||||
:block/created-at 1668152029261,
|
||||
:block/updated-at 1668152029261}
|
||||
{:block/name "thu, 08.09.2022",
|
||||
:block/created-at 1663569715083,
|
||||
:block/updated-at 1663569715083}
|
||||
{:block/name "thu, 09.06.2022",
|
||||
:block/created-at 1668152029730,
|
||||
:block/updated-at 1668152029730}
|
||||
{:block/name "thu, 12.05.2022",
|
||||
:block/created-at 1668152030354,
|
||||
:block/updated-at 1668152030354}
|
||||
{:block/name "thu, 14.07.2022",
|
||||
:block/created-at 1668152029106,
|
||||
:block/updated-at 1668152029106}
|
||||
{:block/name "thu, 16.06.2022",
|
||||
:block/created-at 1668152029690,
|
||||
:block/updated-at 1668152029690}
|
||||
{:block/name "thu, 17.11.2022",
|
||||
:block/created-at 1669014697539,
|
||||
:block/updated-at 1669014697539}
|
||||
{:block/name "thu, 19.05.2022",
|
||||
:block/created-at 1668152030138,
|
||||
:block/updated-at 1668152030138}
|
||||
>>>>>>> 171aabfa957c7f3a81be83ded715c04b953b7bc5
|
||||
{:block/name "thu, 23.06.2022",
|
||||
:block/created-at 1655965420949,
|
||||
:block/updated-at 1655972846769}
|
||||
{:block/name "thu, 26.05.2022",
|
||||
<<<<<<< HEAD
|
||||
:block/created-at 1663845533019,
|
||||
:block/updated-at 1663845533019}
|
||||
{:block/name "thu, 28.07.2022",
|
||||
|
@ -466,6 +684,16 @@
|
|||
{:block/name "thu, 30.06.2022",
|
||||
:block/created-at 1663845532492,
|
||||
:block/updated-at 1663845532492}
|
||||
=======
|
||||
:block/created-at 1668152030008,
|
||||
:block/updated-at 1668152030008}
|
||||
{:block/name "thu, 28.07.2022",
|
||||
:block/created-at 1668152029001,
|
||||
:block/updated-at 1668152029001}
|
||||
{:block/name "thu, 30.06.2022",
|
||||
:block/created-at 1668152029397,
|
||||
:block/updated-at 1668152029397}
|
||||
>>>>>>> 171aabfa957c7f3a81be83ded715c04b953b7bc5
|
||||
{:block/name "todo",
|
||||
:block/created-at 1645528617369,
|
||||
:block/updated-at 1645528617369}
|
||||
|
@ -475,6 +703,7 @@
|
|||
{:block/name "trigonometria",
|
||||
:block/created-at 1652354522035,
|
||||
:block/updated-at 1652354522035}
|
||||
<<<<<<< HEAD
|
||||
<<<<<<< HEAD
|
||||
{:block/name "tue, 03.05.2022",
|
||||
:block/created-at 1663845533417,
|
||||
|
@ -510,19 +739,54 @@
|
|||
:block/created-at 1663845533450,
|
||||
:block/updated-at 1663845533450}
|
||||
=======
|
||||
=======
|
||||
{:block/name "tue, 03.05.2022",
|
||||
:block/created-at 1668152030468,
|
||||
:block/updated-at 1668152030468}
|
||||
>>>>>>> 171aabfa957c7f3a81be83ded715c04b953b7bc5
|
||||
{:block/name "tue, 04.10.2022",
|
||||
:block/created-at 1664875951125,
|
||||
:block/updated-at 1664876122866}
|
||||
{:block/name "tue, 05.07.2022",
|
||||
:block/created-at 1668152029306,
|
||||
:block/updated-at 1668152029306}
|
||||
{:block/name "tue, 06.09.2022",
|
||||
:block/created-at 1662460830170,
|
||||
:block/updated-at 1662479520391}
|
||||
{:block/name "tue, 12.07.2022",
|
||||
:block/created-at 1668152029147,
|
||||
:block/updated-at 1668152029147}
|
||||
{:block/name "tue, 15.11.2022",
|
||||
:block/created-at 1668503113386,
|
||||
:block/updated-at 1668503155008}
|
||||
{:block/name "tue, 17.05.2022",
|
||||
:block/created-at 1668152030223,
|
||||
:block/updated-at 1668152030223}
|
||||
{:block/name "tue, 20.09.2022",
|
||||
:block/created-at 1663643943979,
|
||||
:block/updated-at 1663644804346}
|
||||
<<<<<<< HEAD
|
||||
{:block/name "tue, 27.09.2022",
|
||||
:block/created-at 1664261607414,
|
||||
:block/updated-at 1664261607414}
|
||||
>>>>>>> ec465b2eb07b2d5c554b6034394308363b1c1365
|
||||
=======
|
||||
{:block/name "tue, 24.05.2022",
|
||||
:block/created-at 1668152030064,
|
||||
:block/updated-at 1668152030064}
|
||||
{:block/name "tue, 26.07.2022",
|
||||
:block/created-at 1668152029070,
|
||||
:block/updated-at 1668152029070}
|
||||
{:block/name "tue, 28.06.2022",
|
||||
:block/created-at 1668152029457,
|
||||
:block/updated-at 1668152029457}
|
||||
{:block/name "tue, 31.05.2022",
|
||||
:block/created-at 1668152029843,
|
||||
:block/updated-at 1668152029843}
|
||||
{:block/name "type",
|
||||
:block/created-at 1668152030505,
|
||||
:block/updated-at 1668152030505}
|
||||
>>>>>>> 171aabfa957c7f3a81be83ded715c04b953b7bc5
|
||||
{:block/name "typescript",
|
||||
:block/created-at 1657473564163,
|
||||
:block/updated-at 1657473564163}
|
||||
|
@ -530,8 +794,13 @@
|
|||
:block/created-at 1654096254155,
|
||||
:block/updated-at 1654096254155}
|
||||
{:block/name "uid",
|
||||
<<<<<<< HEAD
|
||||
:block/created-at 1663845533177,
|
||||
:block/updated-at 1663845533177}
|
||||
=======
|
||||
:block/created-at 1668152030173,
|
||||
:block/updated-at 1668152030173}
|
||||
>>>>>>> 171aabfa957c7f3a81be83ded715c04b953b7bc5
|
||||
{:block/name "ultimo teorema di fermat",
|
||||
:block/created-at 1652858740882,
|
||||
:block/updated-at 1652858740882}
|
||||
|
@ -551,6 +820,7 @@
|
|||
:block/created-at 1645528617364,
|
||||
:block/updated-at 1645528617364}
|
||||
{:block/name "wed, 01.06.2022",
|
||||
<<<<<<< HEAD
|
||||
:block/created-at 1663845532888,
|
||||
:block/updated-at 1663845532888}
|
||||
{:block/name "wed, 04.05.2022",
|
||||
|
@ -598,6 +868,61 @@
|
|||
:block/created-at 1663753412828,
|
||||
:block/updated-at 1663753412828}
|
||||
>>>>>>> ec465b2eb07b2d5c554b6034394308363b1c1365
|
||||
=======
|
||||
:block/created-at 1668152029826,
|
||||
:block/updated-at 1668152029826}
|
||||
{:block/name "wed, 04.05.2022",
|
||||
:block/created-at 1668152030459,
|
||||
:block/updated-at 1668152030459}
|
||||
{:block/name "wed, 06.07.2022",
|
||||
:block/created-at 1668152029283,
|
||||
:block/updated-at 1668152029283}
|
||||
{:block/name "wed, 07.09.2022",
|
||||
:block/created-at 1662501600322,
|
||||
:block/updated-at 1662545651026}
|
||||
{:block/name "wed, 08.06.2022",
|
||||
:block/created-at 1668152029767,
|
||||
:block/updated-at 1668152029767}
|
||||
{:block/name "wed, 11.05.2022",
|
||||
:block/created-at 1668152030381,
|
||||
:block/updated-at 1668152030381}
|
||||
{:block/name "wed, 12.10.2022",
|
||||
:block/created-at 1668096142684,
|
||||
:block/updated-at 1668152028762}
|
||||
{:block/name "wed, 14.09.2022",
|
||||
:block/created-at 1668096142633,
|
||||
:block/updated-at 1668152028882}
|
||||
{:block/name "wed, 15.06.2022",
|
||||
:block/created-at 1668152029708,
|
||||
:block/updated-at 1668152029708}
|
||||
{:block/name "wed, 16.11.2022",
|
||||
:block/created-at 1669014697495,
|
||||
:block/updated-at 1669014719913}
|
||||
{:block/name "wed, 18.05.2022",
|
||||
:block/created-at 1668152030179,
|
||||
:block/updated-at 1668152030179}
|
||||
{:block/name "wed, 19.10.2022",
|
||||
:block/created-at 1668096142795,
|
||||
:block/updated-at 1668152028713}
|
||||
{:block/name "wed, 20.07.2022",
|
||||
:block/created-at 1668152029090,
|
||||
:block/updated-at 1668152029090}
|
||||
{:block/name "wed, 21.09.2022",
|
||||
:block/created-at 1663753412828,
|
||||
:block/updated-at 1663753412828}
|
||||
{:block/name "wed, 22.06.2022",
|
||||
:block/created-at 1668152029581,
|
||||
:block/updated-at 1668152029581}
|
||||
{:block/name "wed, 25.05.2022",
|
||||
:block/created-at 1668152030035,
|
||||
:block/updated-at 1668152030035}
|
||||
{:block/name "wed, 29.06.2022",
|
||||
:block/created-at 1668152029431,
|
||||
:block/updated-at 1668152029431}
|
||||
{:block/name "wireguard",
|
||||
:block/created-at 1668096142832,
|
||||
:block/updated-at 1668152028668}
|
||||
>>>>>>> 171aabfa957c7f3a81be83ded715c04b953b7bc5
|
||||
{:block/name "youtube",
|
||||
:block/created-at 1655632371232,
|
||||
:block/updated-at 1655632371232}
|
||||
|
|
257
util/fix-pages-metadata-conflicts.py
Normal file
257
util/fix-pages-metadata-conflicts.py
Normal file
|
@ -0,0 +1,257 @@
|
|||
#!/usr/bin/env python3
|
||||
from pathlib import Path
|
||||
from typing import Union, Tuple, List, NamedTuple, Dict
|
||||
import sys
|
||||
|
||||
|
||||
class Block(NamedTuple):
|
||||
name: str
|
||||
created: int
|
||||
updated: int
|
||||
|
||||
|
||||
def skip_space(s: str, pos: int) -> int:
|
||||
while s[pos].isspace():
|
||||
pos += 1
|
||||
return pos
|
||||
|
||||
|
||||
def consume(s: str, pos: int, c: str) -> Tuple[bool, int]:
|
||||
if s[pos] == c:
|
||||
return (True, pos + 1)
|
||||
else:
|
||||
return (False, pos)
|
||||
|
||||
|
||||
def parse_key(s: str, pos: int) -> Tuple[Union[str, None], int]:
|
||||
if s[pos] != ":":
|
||||
return (None, pos)
|
||||
else:
|
||||
pos += 1
|
||||
key = ""
|
||||
while not s[pos].isspace():
|
||||
key += s[pos]
|
||||
pos += 1
|
||||
return (key, pos)
|
||||
|
||||
|
||||
def parse_str(s: str, pos: int) -> Tuple[Union[str, None], int]:
|
||||
ok, pos = consume(s, pos, '"')
|
||||
if not ok:
|
||||
return (None, pos)
|
||||
res: List[str] = []
|
||||
prev_is_backslash = False
|
||||
while True:
|
||||
if s[pos] == '"':
|
||||
pos += 1
|
||||
if prev_is_backslash:
|
||||
prev_is_backslash = False
|
||||
res.append('"')
|
||||
else:
|
||||
break
|
||||
elif s[pos] == "\\":
|
||||
if prev_is_backslash: # two consecutive backslashes
|
||||
prev_is_backslash = False
|
||||
else:
|
||||
prev_is_backslash = True
|
||||
res.append(s[pos])
|
||||
pos += 1
|
||||
else:
|
||||
prev_is_backslash = False
|
||||
res.append(s[pos])
|
||||
pos += 1
|
||||
return ("".join(res), pos)
|
||||
|
||||
|
||||
def parse_int(s: str, pos: int) -> Tuple[Union[int, None], int]:
|
||||
if s[pos] == "-":
|
||||
sgn = -1
|
||||
pos += 1
|
||||
else:
|
||||
sgn = 1
|
||||
if not s[pos].isdigit():
|
||||
return (None, pos)
|
||||
val = 0
|
||||
while s[pos].isdigit():
|
||||
val = val * 10 + int(s[pos])
|
||||
pos += 1
|
||||
return (sgn * val, pos)
|
||||
|
||||
|
||||
def parse_value(s: str, pos: int) -> Tuple[Union[str, int, None], int]:
|
||||
pos = skip_space(s, pos)
|
||||
v, pos = parse_str(s, pos)
|
||||
if v is not None:
|
||||
return (v, pos)
|
||||
v, pos = parse_int(s, pos)
|
||||
if v is not None:
|
||||
return (v, pos)
|
||||
return (None, pos)
|
||||
|
||||
|
||||
def parse_block(s: str, pos: int) -> Tuple[Union[Block, None], int]:
|
||||
kv: Dict[str, Union[str, int]] = {}
|
||||
pos = skip_space(s, pos)
|
||||
ok, pos = consume(s, pos, "{")
|
||||
if not ok:
|
||||
return (None, pos)
|
||||
while True:
|
||||
pos = skip_space(s, pos)
|
||||
|
||||
# k-v pair
|
||||
key, pos = parse_key(s, pos)
|
||||
if not key:
|
||||
return (None, pos)
|
||||
pos = skip_space(s, pos)
|
||||
val, pos = parse_value(s, pos)
|
||||
if not val:
|
||||
return (None, pos)
|
||||
kv[key] = val
|
||||
|
||||
pos = skip_space(s, pos)
|
||||
|
||||
# end of block
|
||||
ok, pos = consume(s, pos, "}")
|
||||
if ok:
|
||||
break
|
||||
|
||||
# next k-v pair
|
||||
ok, pos = consume(s, pos, ",")
|
||||
if not ok:
|
||||
return (None, pos)
|
||||
|
||||
blk = Block(kv["block/name"], kv["block/created-at"], kv["block/updated-at"])
|
||||
return (blk, pos)
|
||||
|
||||
|
||||
def parse_pages_metadata(s: str) -> Union[List[Block], None]:
|
||||
blocks: List[Block] = []
|
||||
pos = 0
|
||||
pos = skip_space(s, pos)
|
||||
ok, pos = consume(s, pos, "[")
|
||||
if not ok:
|
||||
return None
|
||||
while True:
|
||||
block, pos = parse_block(s, pos)
|
||||
if block is None:
|
||||
break
|
||||
blocks.append(block)
|
||||
pos = skip_space(s, pos)
|
||||
ok, pos = consume(s, pos, "]")
|
||||
if not ok:
|
||||
return None
|
||||
return blocks
|
||||
|
||||
|
||||
def parse_diff(s: str) -> Tuple[bool, Union[str, None], Union[str, None]]:
|
||||
a: List[str] = []
|
||||
b: List[str] = []
|
||||
state = "both"
|
||||
has_conflicts = False
|
||||
for line in s.split("\n"):
|
||||
if line.startswith("<<<<<<< "):
|
||||
has_conflicts = True
|
||||
if state == "both":
|
||||
state = "a"
|
||||
else:
|
||||
return (has_conflicts, None, None)
|
||||
elif line.startswith("======="):
|
||||
if state == "a":
|
||||
state = "b"
|
||||
else:
|
||||
return (has_conflicts, None, None)
|
||||
elif line.startswith(">>>>>>> "):
|
||||
if state == "b":
|
||||
state = "both"
|
||||
else:
|
||||
return (has_conflicts, None, None)
|
||||
else:
|
||||
if state == "a":
|
||||
a.append(line)
|
||||
elif state == "b":
|
||||
b.append(line)
|
||||
else: # 'both'
|
||||
a.append(line)
|
||||
b.append(line)
|
||||
return (has_conflicts, "\n".join(a), "\n".join(b))
|
||||
|
||||
|
||||
def merge_block(a: Block, b: Block) -> Block:
|
||||
created = min(a.created, b.created)
|
||||
updated = max(a.updated, b.updated)
|
||||
return Block(a.name, created, updated)
|
||||
|
||||
|
||||
def merge_blocks(blk_a: List[Block], blk_b: List[Block]) -> List[Block]:
|
||||
blk_a_dict: Dict[str, Block] = {}
|
||||
blk_b_dict: Dict[str, Block] = {}
|
||||
|
||||
for blk in blk_a:
|
||||
blk_a_dict[blk.name] = blk
|
||||
|
||||
for blk in blk_b:
|
||||
blk_b_dict[blk.name] = blk
|
||||
|
||||
res: List[Block] = []
|
||||
for blk in blk_a:
|
||||
if blk.name in blk_b_dict:
|
||||
res.append(merge_block(blk, blk_b_dict[blk.name]))
|
||||
else:
|
||||
res.append(blk)
|
||||
for blk in blk_b:
|
||||
if blk.name not in blk_a_dict:
|
||||
res.append(blk)
|
||||
|
||||
res.sort(key=lambda x: x.name)
|
||||
|
||||
return res
|
||||
|
||||
|
||||
def print_blocks(blks: List[Block]) -> str:
|
||||
res = "["
|
||||
for i, blk in enumerate(blks):
|
||||
if i == 0:
|
||||
s = f'{{:block/name "{blk.name}",\n :block/created-at {blk.created},\n :block/updated-at {blk.updated}}}\n'
|
||||
elif i == len(blks) - 1:
|
||||
s = f' {{:block/name "{blk.name}",\n :block/created-at {blk.created},\n :block/updated-at {blk.updated}}}'
|
||||
else:
|
||||
s = f' {{:block/name "{blk.name}",\n :block/created-at {blk.created},\n :block/updated-at {blk.updated}}}\n'
|
||||
|
||||
res += s
|
||||
res += "]\n"
|
||||
return res
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
if len(sys.argv) > 1:
|
||||
fp = Path(sys.argv[1])
|
||||
else:
|
||||
fp = Path(".")
|
||||
fp = fp / "logseq/pages-metadata.edn"
|
||||
if not fp.exists():
|
||||
print("`pages-metadata.edn` not found")
|
||||
sys.exit(1)
|
||||
with fp.open(encoding="utf-8") as f:
|
||||
content = f.read()
|
||||
conf, a, b = parse_diff(content)
|
||||
if not conf:
|
||||
print("No conflicts found")
|
||||
sys.exit(0)
|
||||
if not a or not b:
|
||||
print("Could not parse diff")
|
||||
sys.exit(1)
|
||||
|
||||
blk_a = parse_pages_metadata(a)
|
||||
blk_b = parse_pages_metadata(b)
|
||||
if not blk_a or not blk_b:
|
||||
print("Could not parse `pages-metadata.edn`")
|
||||
sys.exit(1)
|
||||
blk = merge_blocks(blk_a, blk_b)
|
||||
s = print_blocks(blk)
|
||||
|
||||
fp.unlink()
|
||||
fp.open("w", encoding="utf-8").write(s)
|
||||
|
||||
print("Merged `pages-metadata.edn` successfully")
|
||||
|
||||
sys.exit(0)
|
Loading…
Reference in a new issue