Skip to content

Instantly share code, notes, and snippets.

View mustmodify's full-sized avatar

Johnathon "jw" Wright mustmodify

View GitHub Profile
class RecommendationRowComponent extends React.component {
constructor(props)
{
super(props);
this.state = {expanded: false}
}
...
}
description "Reporting - HTTP"
start on (local-filesystems and net-device-up IFACE=lo and runlevel [2345])
stop on (runlevel [!2345])
respawn
respawn limit 3 30
setuid jv
script
jw@adaline:~$ ls -l /
total 10485976
drwxr-xr-x 2 root root 4096 Nov 28 06:49 bin
drwxr-xr-x 3 root root 4096 Nov 28 06:50 boot
drwxr-xr-x 11 root root 3160 Dec 20 00:20 dev
-rw-r--r-- 1 root root 16140 Dec 20 10:56 dump.rdb
drwxr-xr-x 100 root root 4096 Dec 11 06:40 etc
drwxr-xr-x 9 root root 4096 Jul 17 13:55 home
lrwxrwxrwx 1 root root 30 Nov 15 06:49 initrd.img -> boot/initrd.img-4.4.0-1072-aws
lrwxrwxrwx 1 root root 30 Oct 23 06:28 initrd.img.old -> boot/initrd.img-4.4.0-1070-aws
jw@adaline:/$ mount
sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
udev on /dev type devtmpfs (rw,nosuid,relatime,size=3899452k,nr_inodes=974863,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /run type tmpfs (rw,nosuid,noexec,relatime,size=781484k,mode=755)
/dev/nvme0n1p1 on / type ext4 (rw,relatime,discard,data=ordered)
none on /sys/fs/cgroup type tmpfs (rw,relatime,size=4k,mode=755)
none on /sys/fs/fuse/connections type fusectl (rw,relatime)
none on /sys/kernel/debug type debugfs (rw,relatime)
jw@adaline:~$ df -h
Filesystem Size Used Avail Use% Mounted on
udev 3.8G 4.0K 3.8G 1% /dev
tmpfs 764M 496K 763M 1% /run
/dev/nvme0n1p1 243G 91G 153G 38% /
none 4.0K 0 4.0K 0% /sys/fs/cgroup
none 5.0M 0 5.0M 0% /run/lock
none 3.8G 0 3.8G 0% /run/shm
none 100M 0 100M 0% /run/user
tmpfs 100K 0 100K 0% /var/lib/lxd/shmounts
// I'm rewriting a node module here: https://github.com/mustmodify/collection-json.js
// but right now, I'm just trying to figure out one thing. So I have this simplified example.
// How can I make this code available to three audiences:
// * ES6 import/export
// * CommonJS require/module.export
// * non-node devs just doing <script src="..."></script> <script>UseCodeHere</script>
class GreatTool {
hello(geography) {
jw@logopolis:/projects/open/collection-json.js$ npx webpack
Hash: ccbff4e2def16e85bf23
Version: webpack 4.26.1
Time: 1494ms
Built at: 2018-12-03 22:13:52
Asset Size Chunks Chunk Names
collection-json.js 1.05 MiB 0 [emitted] [big] main
Entrypoint main [big] = collection-json.js
[10] (webpack)/buildin/global.js 472 bytes {0} [built]
[14] ./src/http.js 3.07 KiB {0} [built]
export default class Client {
constructor(blah) {
}
static parse(a) {
return "clients like " + a + " are bad";
}
}
class Tester():
something = "initial"
def setup(self):
self.something = "one"
something = "hello"
Tester.something = "OMGZ!!!"
try:
print("local var: " + something)
SELECT ov.id
FROM visits AS ov
WHERE ROW(ov.patient_id, ov.date) IN
(
SELECT iv.patient_id, MIN(iv.date)
FROM visits iv
GROUP BY iv.patient_id
)