@@ 1,28 @@
+<p>
+ This repository demonstrates how to set a
+ <a href="https://man.sr.ht/git.sr.ht/#setting-a-custom-readme"
+ >custom README</a
+ >
+ with the development version of
+ <a href="https://sr.ht/~emersion/hut/">hut</a>.
+</p>
+<h2 id="setting-the-custom-readme">Setting the custom README</h2>
+<p>
+ <code
+ >hut git update --readme readme.html --repo
+ https://git.xenrox.net/~xenrox/custom-readme</code
+ >
+</p>
+<h2 id="removing-the-custom-readme">Removing the custom README</h2>
+<p>
+ If you want to go back to sourcehut's default way of rendering the
+ README from markdown, you can do this by manually executing a GraphQL
+ mutation. <code>hut</code> does not yet support this functionality.
+</p>
+<pre><code class="lang-bash"><span class="hljs-comment"># enter your own OAuth2 token</span>
+<span class="hljs-built_in">export</span> TOKEN=<span class="hljs-string">"YourOAuth2Token"</span>
+<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>
+</code></pre>