- shutdown the mac
- start the mac holding the power on button indefinitly
diskutils list internal| import 'package:flutter/material.dart'; | |
| void main() => runApp(MyApp()); | |
| class MyApp extends StatelessWidget { | |
| @override | |
| Widget build(BuildContext context) { | |
| return MaterialApp(home: MyPage()); | |
| } | |
| } |
| class FooSliver extends SingleChildRenderObjectWidget { | |
| const FooSliver({super.key, super.child}); | |
| @override | |
| RenderObject createRenderObject(BuildContext context) => FooRenderSliver(); | |
| } | |
| class BarSliver extends SingleChildRenderObjectWidget { | |
| const BarSliver({super.key, super.child = const Text("Hello from Bar")}); |
| function fixwrongjpeg() { | |
| find . -name "*.jpg" | while IFS= read -r file; do | |
| mime=$(file --mime-type -b "$file") | |
| if [[ $mime != image/jpeg ]]; then | |
| mv "$file" "$file.wrong" | |
| convert "$file.wrong" "$file" | |
| echo "fixed $file" | |
| rm "$file.wrong" | |
| fi | |
| done |
| // ********************************************************** | |
| // MARK: - AudioBus MIDI Input | |
| // ********************************************************** | |
| extension ParentViewController { | |
| func setupAudioBusInput() { | |
| midiInput = ABMIDIReceiverPort(name: "FM Player MIDI In", title: "FM Player MIDI In") { (port, midiPacketListPointer) in | |
| let events = AKMIDIEvent.midiEventsFrom(packetListPointer: midiPacketListPointer) |
| p (char *) object_getClassName(*(long*)($x0)) | |
| p (char *) $x1 | |
| p (char *) $x2 | |
| #!/bin/sh -x | |
| cd /tmp | |
| if [ ! -d "geocouch" ]; then | |
| git clone https://github.com/couchbase/geocouch.git | |
| fi | |
| cd geocouch | |
| git checkout couchdb1.2.x |
| // relay.js | |
| var util = require('util'); | |
| var net = require('net'); | |
| var dns = require('dns'); | |
| var nurl = require('url'); | |
| var host = '127.0.0.1'; | |
| var port = 6969; | |
| var source = ''; |
| [ | |
| { | |
| "hex": "#EFDECD", | |
| "name": "Almond", | |
| "rgb": "(239, 222, 205)" | |
| }, | |
| { | |
| "hex": "#CD9575", | |
| "name": "Antique Brass", | |
| "rgb": "(205, 149, 117)" |
| /* | |
| In the node.js intro tutorial (http://nodejs.org/), they show a basic tcp | |
| server, but for some reason omit a client connecting to it. I added an | |
| example at the bottom. | |
| Save the following server in example.js: | |
| */ | |
| var net = require('net'); |