www

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | Submodules | README

cmd.sh (1303B)


      1 mv localhost "localhost_$(date)"
      2 
      3 (cd ../zimmer; npm install)
      4 
      5 ../zimmer/wikizimmer.js http://localhost/mediawiki/index.php/Accueil \
      6   --pages 'Accueil|Affichage_Graphique|Conventions|Drivers/mode_reel.h:int86|Environnement_de_programmation|GRUB|Langage|Liens|Notes|Nouveau_Développeur|Prérequis|Test_fonctionC|Toutes_les_pages' \
      7   --content body \
      8   --remove 'script:not(#random-script),a[href*="action=edit"],.editsection,.mw-editsection,#privacy,#about,#disclaimer,#p-personal,#p-cactions-mobile,#p-cactions,#column-one h2,#p-personal-toggle,#globalWrapper-toggle,#p-search,#t-whatlinkshere,#t-recentchangeslinked,#t-permalink,#t-info,#n-recentchanges' $(: ',#t-specialpages') \
      9   --template template.html \
     10   --style stub.css \
     11   --no-default-style \
     12   --verbose \
     13 
     14 sed -i -e 's|./../data:image/svg+xml|data:image/svg+xml|g' localhost/-/zim.css
     15 # remove extra ../ due to the fact that we moved all the pages to the root
     16 find localhost \( -iname '*.html' -o -iname '*.css' \) -print0 | xargs -0 sed -i -e 's|\./\.\./\([-IM]\)/|./\1/|g'
     17 
     18 cp localhost/Accueil.html localhost/index.html
     19 
     20 cid="$(ipfs cid base32 "$(ipfs add --recursive --progress --hidden --quieter --pin=false localhost)" | sed -e 's|^|https://|;s|$|.ipfs.dweb.link|')"
     21 
     22 (printf %s "$cid" | wl-copy) || true
     23 
     24 printf \\n%s\\n "$cid"