A .build.yml => .build.yml +10 -0
@@ 0,0 1,10 @@
+image: archlinux
+oauth: git.sr.ht/REPOSITORIES:RW git.sr.ht/PROFILE:RO
+packages:
+ - hut-git
+sources:
+ - https://git.xenrox.net/~xenrox/custom-readme
+tasks:
+ - update-readme: |
+ cd custom-readme
+ hut git update --readme readme.html
M readme.html => readme.html +7 -1
@@ 8,10 8,16 @@
</p>
<h2 id="setting-the-custom-readme">Setting the custom README</h2>
<p>
+ Either use this command
<code
>hut git update --readme readme.html --repo
https://git.xenrox.net/~xenrox/custom-readme</code
>
+ or use an automatic deployment with a
+ <a
+ href="https://git.xenrox.net/~xenrox/custom-readme/tree/master/item/.build.yml"
+ >build manifest</a
+ >.
</p>
<h2 id="removing-the-custom-readme">Removing the custom README</h2>
<p>
@@ 24,5 30,5 @@
<span class="hljs-comment"># find out the ID of your repository</span>
curl --oauth2-bearer <span class="hljs-variable">$TOKEN</span> https://git.sr.ht/query <span class="hljs-_">-d</span> <span class="hljs-string">'{"query": "query { me { repository(name: \"custom-readme\"){ id } } }"}'</span>
<span class="hljs-comment"># remove custom README</span>
-curl --oauth2-bearer <span class="hljs-variable">$TOKEN</span> https://git.sr.ht/query <span class="hljs-_">-d</span> <span class="hljs-string">'{"query": "mutation{ updateRepository(id: 70332, input: { readme: null }) { id } }"}'</span>
+curl --oauth2-bearer <span class="hljs-variable">$TOKEN</span> https://git.sr.ht/query <span class="hljs-_">-d</span> <span class="hljs-string">'{"query": "mutation{ updateRepository(id: 42, input: { readme: null }) { id } }"}'</span>
</code></pre>