From 237f5efb852a2acaa2fd4b7740472727430a59bf Mon Sep 17 00:00:00 2001 From: catvayor Date: Thu, 12 Dec 2024 18:08:43 +0100 Subject: [PATCH] chore: remove external site imports --- ...02-chore-remove-useless-dependencies.patch | 24 ++++++++++ .../hugo-theme-extranix-options-search.nix | 45 ++++++++++++++++-- .../kat-son/static-data/images/favicon.ico | Bin 0 -> 4286 bytes .../kat-son/static-data/images/favicon.png | Bin 0 -> 1067 bytes 4 files changed, 65 insertions(+), 4 deletions(-) create mode 100644 machines/kat-son/doc/0002-chore-remove-useless-dependencies.patch create mode 100644 machines/kat-son/static-data/images/favicon.ico create mode 100644 machines/kat-son/static-data/images/favicon.png diff --git a/machines/kat-son/doc/0002-chore-remove-useless-dependencies.patch b/machines/kat-son/doc/0002-chore-remove-useless-dependencies.patch new file mode 100644 index 0000000..74b8cb9 --- /dev/null +++ b/machines/kat-son/doc/0002-chore-remove-useless-dependencies.patch @@ -0,0 +1,24 @@ +From d32ae9c3386ad1d896d8a54271138111b579d7e7 Mon Sep 17 00:00:00 2001 +From: catvayor +Date: Thu, 12 Dec 2024 17:04:45 +0100 +Subject: [PATCH 2/2] chore: remove useless dependencies + +--- + layouts/index.html | 1 - + 1 file changed, 1 deletion(-) + +diff --git a/layouts/index.html b/layouts/index.html +index 63a6158..780ea78 100644 +--- a/layouts/index.html ++++ b/layouts/index.html +@@ -17,7 +17,6 @@ + + + +- + + + +-- +2.47.0 + diff --git a/machines/kat-son/doc/hugo-theme-extranix-options-search.nix b/machines/kat-son/doc/hugo-theme-extranix-options-search.nix index cfcbba6..df95ade 100644 --- a/machines/kat-son/doc/hugo-theme-extranix-options-search.nix +++ b/machines/kat-son/doc/hugo-theme-extranix-options-search.nix @@ -2,6 +2,7 @@ fetchFromGitHub, stdenv, lib, + fetchurl, }: stdenv.mkDerivation { name = "hugo-theme-extranix-options-search"; @@ -15,12 +16,48 @@ stdenv.mkDerivation { patches = [ ./0001-fix-pretty-no-defaults.patch + ./0002-chore-remove-useless-dependencies.patch ]; - installPhase = '' - mkdir $out - cp -r * $out - ''; + installPhase = + let + js-search = fetchurl { + url = "https://unpkg.com/js-search@2.0.1/dist/umd/js-search.min.js"; + hash = "sha256-LD9UsSATk+xTzAbk8nD2gA2bjHKvetXtCMDAFkM2K5Q="; + }; + jquery = fetchurl { + url = "https://code.jquery.com/jquery-3.7.1.slim.min.js"; + hash = "sha256-kmHvs0B+OpCW5GVHUNjv9rOmY0IvSIRcf7zGUDTDQM8="; + }; + bootstrap.css.main = fetchurl { + url = "https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css"; + hash = "sha256-916EbMg70RQy9LHiGkXzG8hSg9EdNy97GazNG/aiY1w="; + }; + bootstrap.css.theme = fetchurl { + url = "https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap-theme.min.css"; + hash = "sha256-ZT4HPpdCOt2lvDkXokHuhJfdOKSPFLzeAJik5U/Q+l4="; + }; + bootstrap.js = fetchurl { + url = "https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"; + hash = "sha256-U5ZEeKfGNOja007MMD3YBI0A3OSZOQbeG6z2f2Y0hu8="; + }; + in + '' + mkdir $out + rm static/images/favicon.* + cp -r * $out + cp ${js-search} $out/static/js/js-search.min.js + cp ${jquery} $out/static/js/jquery.slim.min.js + cp ${bootstrap.css.main} $out/static/css/bootstrap.min.css + cp ${bootstrap.css.theme} $out/static/css/bootstrap-theme.min.css + cp ${bootstrap.js} $out/static/js/bootstrap.min.js + substituteInPlace $out/layouts/index.html \ + --replace-fail 'https://unpkg.com/js-search@2.0.1/dist/umd/js-search.min.js' js/js-search.min.js \ + --replace-fail 'https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js' js/jquery.slim.min.js \ + --replace-fail 'https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css' css/bootstrap.min.css \ + --replace-fail 'https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap-theme.min.css' css/bootstrap-theme.min.css \ + --replace-fail 'https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js' js/bootstrap.min.js \ + ''; meta = { description = "Theme which implements a nix modules options search machine."; diff --git a/machines/kat-son/static-data/images/favicon.ico b/machines/kat-son/static-data/images/favicon.ico new file mode 100644 index 0000000000000000000000000000000000000000..4cf5eacfcc59399c68ce594b19465565e0f19e90 GIT binary patch literal 4286 zcmb_fSxl8j6#lOlK?D?)u&8(y1wlYIx1a*<)l_kLpe7{&l2QrOs7a%S)Ld&zj7{p3 zX^bST_JKZ_8j?O>=mSlCs1F5V)1=fUVycqbL?~q~%jx$Wn495e2?mFJ%*>gY^Ua(& z=lpXW$AiDss~!G#zKL|4XvcAq0f?LefO0Jun`3!z&6+imk&z+L6F_8Sq^w%CO48EO zq@to?WYMBUKViHG@XnFXUe4YB1xR#swCvu!JHSsFv3c`mS+Zn_E&mNdf*t!khh7B8Rn@?EF`Ow=q6FJ7dBsW1W<`>gvot&I3 zxw*M=>eMOar++XW>^al5$N5Jwo(fDVxZ^zN8o_|-^LRY!>+EwM+qZ95Utk}0ly&RY zNk~YD&Y^Ce-K@21<_!94e0;na{}kiy;@Q7{|1b1k+LHR1a}ORosJzx%>FMc#8;zCG z(NTHwvHMRCAob0 zvJ4LoOH)%5@4zn1kZCnro4&q2dH(#l#v^64&5av3bPwmw zofGc!<;#~cI5?;|s<^mVxfzT7{rys3Ur&8@sX<3`$JVV|B{4Bk`DjPVDYNp3+MhP( zzPO(=XU@pcqeqp$rKLqmN=md{S68R&_wL=Rxw^HrRYpce-24gP=qJz0l`F;P^XVG) z4L|*m_MnWQ{mIWZa}4)aP*9+{DK9N8RsJhiu1H*5oZ69j{O;Ym^5DS(Ie-2<*P3z< z4b?>+`XBp@d)mv4(azi-`!+v(NoBMdOLKE`z!vlkp55qRO*=AopzR>9zGaWGO?$GQ zD!()DaLn-2$IUnA?Af!*fAi)|y?@?wXJ=<1ez}hR#Qo5}&<`prEBlji%rOJQZ)|Vm zteO95AM(F=@j|d(zYBi9Uwy5kqeFJ>+9k`DEmMEvhT7WNc`>Fw>+v)caD!qhj99XqCX;q`iH z>yLr2XnSLS#xQd^zi;$ao6qDhFV%|rXKcSpH zeY%=9ci$!Bnz4b&lQ4x|ox}G6ZDDe?Yu=C0HQn2b{y2$;F~A(-9&_oPG|s%qw}Cb9 zSLlcXW-6axaFQ>O=mQ`L+o{3heui0|GgU^a!nnf?X>d~EX_VSZ=uEj*P? z%o=|G8OQX0_}2H3zwWP3{*0|N`b^E7#{?J3mZLy{9Rx!B^`^u z0R9CumiO)3r}=<=g8t6$GGk>tKeRypJ`f7LsS*K2g}`Sx|98l%Pr>;Ne*PG5{U0E& z1<08Q%(_UISESt$X>#%bpZJ}{KnM=T1ntEG%`-d(X8>A>E}(rJO{fX~I8d>8{A2Jo XIZjCX7#3rl54!T9Q^XJ6E}#4lHHE9x literal 0 HcmV?d00001 diff --git a/machines/kat-son/static-data/images/favicon.png b/machines/kat-son/static-data/images/favicon.png new file mode 100644 index 0000000000000000000000000000000000000000..a08469d5fc390bc688222a9abd16c1d46738be63 GIT binary patch literal 1067 zcmV+`1l0S9P)kdg0000WV@Og>004R> z004l5008;`004mK004C`008P>0026e000+ooVrmw00002VoOIv0RM-N%)bBt1Gq^< zK~zY`jg?DGTy+%2fA=yoNFQbx8=y0Q1sOBE3dr11kPhug)kG5%7cEJnG1X|}BhfBQ z+ZdzPF1k>6jd9^?VN851>e4n^Hi|7+48G8|0;S+!kY{li_*~4r^8niV-OZfyKi_x$ zch2J)tcT6SXv?pDvA!qIyxKQ5H^ldxW{CfVdQLEl4DD7#2-T=fmfWJBrzp5SxrmQZ z>WL{|wc21?d8$^kw#yi0-?iy`i97VWkroWa631;ODuc9}pD&-qwYZm+YBdsd5LjtPKB4i5`D=JUM*F&Dezcn(C zYIUDB%O@)*V>s(q&1&Dvj=&d=t6fJFTt}c#QEjw6x2VE7U7`+5n&@2 zJF78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