Skip to content

Instantly share code, notes, and snippets.

@khoadng
khoadng / hello.json
Last active April 1, 2026 07:30
chanh bundle test - Hello page
{"v":1,"entry":"hello.dart","files":{"hello.dart":"import 'package:flutter/material.dart';class MyWidget extends StatelessWidget{Widget build(BuildContext a){return Center(child: Column(mainAxisAlignment: MainAxisAlignment.center,children:[Icon(Icons.flutter_dash,size: 64.0),SizedBox(height: 106.0),Text('Hello Simon!',style: TextStyle(fontSize: 24.0))]));}} MyWidget main() => MyWidget();"}}
@khoadng
khoadng / neofetch.dart
Last active March 26, 2026 14:56
TyphonOS neofetch
import 'package:typhon_api/typhon_api.dart';
void main(SysCall sys) {
final user = sys.env['USER'] ?? 'unknown';
final host = sys.hostname;
final home = sys.env['HOME'] ?? '/';
final pid = sys.pid;
final uid = sys.uid;
final title = '$user@$host';
void main() {
print('Hello from Gist');
}
@khoadng
khoadng / gist:14b10ac850463955a6f15f56eb94c53d
Created January 17, 2021 06:27
Regex expression for hardcoded string
(?=(^((?!///).)*$)).*((".+?")|('.+?')).*