diff --git a/Makefile b/Makefile index e9d3f02cf33d41c23e8cfc4c18ab71c406809d97..e31c6e7fbebf76e0ac34efe59425254d454e3715 100644 --- a/Makefile +++ b/Makefile @@ -30,29 +30,36 @@ cours.html: 00_macros.md 01_rappel.md 02_optimisation.md 03_integrales.md 04_edo hakyll_gen: 1_Rappel.markdown 2_Optimisation.markdown 3_Integrales.markdown 4_Equation_Differentielles_Ordinaires.markdown 5_Transformees_de_Fourier.markdown 6_Probabilites_et_Statistique.markdown 7_Remerciements.markdown -macros: 00_macros.md - sed "1i ---\ndate: $(shell date +%y%y-%m-%d)\n---" $< > $@ +# macros: 00_macros.md +# sed "1i ---\ndate: $(shell git log --follow -p -1 --format=%cd --date=format:'%Y-%m-%d' -- 02_optimisation.md | head -n 1)\n---" $< > $@ -1_Rappel.markdown: macros 01_rappel.md 08_notes.md +1_Rappel.markdown: 00_macros.md 01_rappel.md 08_notes.md cat $^ > $@ + sed -i "1i ---\ndate: $(shell git log --follow -p -1 --format=%cd --date=format:'%Y-%m-%d' -- 01_rappel.md | head -n 1)\n---" $@ -2_Optimisation.markdown: macros 02_optimisation.md 08_notes.md +2_Optimisation.markdown: 00_macros.md 02_optimisation.md 08_notes.md cat $^ > $@ + sed -i "1i ---\ndate: $(shell git log --follow -p -1 --format=%cd --date=format:'%Y-%m-%d' -- 02_optimisation.md | head -n 1)\n---" $@ -3_Integrales.markdown: macros 03_integrales.md 08_notes.md +3_Integrales.markdown: 00_macros.md 03_integrales.md 08_notes.md cat $^ > $@ + sed -i "1i ---\ndate: $(shell git log --follow -p -1 --format=%cd --date=format:'%Y-%m-%d' -- 03_integrales.md | head -n 1)\n---" $@ -4_Equation_Differentielles_Ordinaires.markdown: macros 04_edo.md 08_notes.md +4_Equation_Differentielles_Ordinaires.markdown: 00_macros.md 04_edo.md 08_notes.md cat $^ > $@ + sed -i "1i ---\ndate: $(shell git log --follow -p -1 --format=%cd --date=format:'%Y-%m-%d' -- 04_edo.md | head -n 1)\n---" $@ -5_Transformees_de_Fourier.markdown: macros 05_fourier.md 08_notes.md +5_Transformees_de_Fourier.markdown: 00_macros.md 05_fourier.md 08_notes.md cat $^ > $@ + sed -i "1i ---\ndate: $(shell git log --follow -p -1 --format=%cd --date=format:'%Y-%m-%d' -- 05_fourier.md | head -n 1)\n---" $@ -6_Probabilites_et_Statistique.markdown: macros 06_probas_stats.md 08_notes.md +6_Probabilites_et_Statistique.markdown: 00_macros.md 06_probas_stats.md 08_notes.md cat $^ > $@ + sed -i "1i ---\ndate: $(shell git log --follow -p -1 --format=%cd --date=format:'%Y-%m-%d' -- 06_probas_stats.md | head -n 1)\n---" $@ -7_Remerciements.markdown: macros 07_remerciements.md 08_notes.md +7_Remerciements.markdown: 00_macros.md 07_remerciements.md 08_notes.md cat $^ > $@ + sed -i "1i ---\ndate: $(shell git log --follow -p -1 --format=%cd --date=format:'%Y-%m-%d' -- 07_remerciements.md | head -n 1)\n---" $@ deploy: all @@ -73,4 +80,4 @@ deploy: all cp travaux_pratiques/tpOptimisation/tpOptimisation.html mti/tpOptimisation/index.html clean: - rm -rf mti *.markdown macros *.html *.pdf + rm -rf mti *.markdown *.html *.pdf