Skip to content

Instantly share code, notes, and snippets.

How to move root volume of this image

This image: Arch Linux Image for VisionFive 2

Author "cwt" briefly wrote below:

If you wish to mount NVMe as the root partition, please format it as btrfs and then create a subvolume with the desired name. Mount the path /mnt which already in the /etc/fstab (so just run mount /mnt as root), then use rsync to copy the contents of /mnt/arch-minimal to the new subvolume on the NVMe. Finally, edit the /boot/boot/extlinux/extlinux.conf and the /etc/fstab on the new subvolume.

But I'm totally noob to btrfs & Arch, so I'm going to write down detailed steps.

prerequisites

@ozero
ozero / lambda_telegram_bot_sample.js
Created February 8, 2022 06:20
Telegram bot を AWS API gateway + Lambda でやってみた
/*
https://qiita.com/leokryslov/items/35f98e8e24e797441150
が、そのままでは
- `event.message.text` じゃなく `event.body.message.text` だよね
- API Gatewayが"Malformed Lambda proxy response"とか吐いてた
ということで動くまで直したやつ。
*/
const https = require('https');
@ozero
ozero / sample_and_concept.md
Last active November 22, 2021 02:56
Humhub: Mounting S3 Using goofys & catfs, allows to more capacity than your VPS.
@ozero
ozero / mouse_dictionary_helper.user.js
Last active May 5, 2022 07:22
Mouse Dictionary で引いた結果をAnkiwebのdeckに登録する君
// ==UserScript==
// @name Mouse dictionary helper
// @namespace http://tampermonkey.net/
// @version 0.4
// @description Mouse Dictionary で引いた結果をAnkiwebのdeckに登録する君
// @author @ozero
// @match *://*/*
// @grant GM.setValue
// @grant GM.getValue
// ==/UserScript==
@ozero
ozero / ahamo_chat_starter.user.js
Last active June 4, 2021 01:02
メロスはAhamoサポートチャットに激怒した。いくらリロードしてチャットボタンをクリックしてもつながらないのだ。メロスは、単純な男であった。激怒に任せてリロード次第「チャットを開く」ボタンを自動クリックするuserscriptを書いたのだ。
// ==UserScript==
// @name Ahamo chat starter
// @namespace http://tampermonkey.net/
// @version 0.1
// @description Ahamo chat starter
// @author You
// @match https://ahamo.com/chat/
// @icon https://www.google.com/s2/favicons?domain=ahamo.com
// @grant none
// ==/UserScript==
@ozero
ozero / head.php
Last active December 22, 2020 03:34
Humhub 1.7.x: Modify mobile view for spaces
<!-- /themes/HumHub/views/layouts/head.php -->
<?php if(Yii::$app->user->isGuest){ ?>
<?php if($_SERVER['REQUEST_URI'] == "/dashboard"){ ?>
<meta http-equiv="refresh" content="0;URL=/p/about">
<?php } ?>
<?php } ?>
<style id="hideSpaceProfileOnMobile">
@media only screen and (max-width: 480px){
/* remove space icon */
@ozero
ozero / goto-eats-osaka-scrape.user.js
Last active November 5, 2020 08:07
Goto Eats Osaka scrape Userscript
// ==UserScript==
// @name Goto Eats Osaka scrape
// @namespace http://tampermonkey.net/
// @version 0.2
// @description 検索だけでマップがないとかクソすぎへん?
// @author You
// @match https://goto-eat.weare.osaka-info.jp/*
// @grant none
// ==/UserScript==
@ozero
ozero / Reduce.php
Last active September 25, 2020 23:34
Humhub: Reduce filesize of attached image.
<?php
/*
# Reduce filesize of attached image.
- for X or Y axis: 1024px max
- compress into Jpeg on q=90
## Usage
### Keybase proof
I hereby claim:
* I am ozero on github.
* I am ozero (https://keybase.io/ozero) on keybase.
* I have a public key ASAwQANAbayWZaDnXiBKsOEkGP0ajTlSm08EuuhLFuUlVwo
To claim this, I am signing this object:
@ozero
ozero / Ingress_Forum_auto_liking.user.js
Created April 24, 2020 11:43
Ingress Forum auto liking
// ==UserScript==
// @name Ingress Forum auto liking
// @namespace http://tampermonkey.net/
// @version 0.0.1.20190610.00
// @description よくあるふぁぼ爆、なお多重実行するとそのままトグルされてキャンセルとなる模様
// @author ozero
// @updateURL https://test.currentdir.com/iitc_plugins/Ingress_Forum_auto_liking.user.js
// @downloadURL https://test.currentdir.com/iitc_plugins/Ingress_Forum_auto_liking.user.js
// @match https://community.ingress.com/*/discussion/*
// @grant none