Skip to content

Instantly share code, notes, and snippets.

View MarkBennett's full-sized avatar

Mark Bennett MarkBennett

View GitHub Profile
@MarkBennett
MarkBennett / installing-ruby-2.5.1-on-m1.md
Last active March 23, 2024 10:21
Installing Ruby 2.5 on Mac M1
@MarkBennett
MarkBennett / gist:4e3d5346a0c8e12c5a3677581586aec9
Created November 27, 2023 18:08
Extracting contributor emails from a git repo
git shortlog -sne | awk '!/users.noreply.github.com/ {count=$1; $1=""; gsub(/^ /,"",$0); name=substr($0,1,index($0,"<")-1); gsub(/[ \t]+$/, "", name); email=tolower(substr($0,index($0,"<")+1)); gsub(/>/,"",email); print count", \""name"\", \""email"\""}' > contributors.csv
@MarkBennett
MarkBennett / LICENSE
Created January 17, 2012 21:44
Debugging JavaScript In the Trenches
Copyright (C) 2012 Mark Bennett, Paul Irish, Aicke Schulz
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to do
so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
@MarkBennett
MarkBennett / json_by_line.js
Last active April 19, 2021 20:38
Output JSON from STDIN Line-By-Line And Pretty Print
/*
* Credit to the Node.js Docs for the line-by-line `ReadStream` example.
*
* https://nodejs.org/api/readline.html#readline_example_read_file_stream_line_by_line
*/
const readline = require('readline');
var stdin = process.stdin;
@MarkBennett
MarkBennett / DESCRIPTION.md
Created September 22, 2012 18:29
Failing to import Go packages

I've just installed Go from the package on the golang site.

When trying to build (or run) import getting an import error, but can't figure out why:

go build world2.go

This produces the error:

# world2.go:3:8: import "world": cannot find package

SETUP ENVIRONMENT, PRIOR TO DEMO

doctl auth init

doctl k8s cluster create --region=tor1 rio-demo

START DEMO

Download and install Rio CLI

Async process failed: Cancel
dojo.js.uncompressed.js:5261 TypeError: Cannot read property 'slice' of undefined
at Object.renderGrid (null:1)
at Object.initReportGrid (null:1)
at Object.handleReportResponse (null:1)
at c (dojo.js.uncompressed.js:4819)
at a (dojo.js.uncompressed.js:4810)
at p.resolve (dojo.js.uncompressed.js:4974)
at d (dojo.js.uncompressed.js:4863)
at c (dojo.js.uncompressed.js:4840)

Keybase proof

I hereby claim:

  • I am markbennett on github.
  • I am markbennett (https://keybase.io/markbennett) on keybase.
  • I have a public key ASAVjXPhy1oIRWhregKYxoqgyJwNJ9DvOknpevsP_lvJBQo

To claim this, I am signing this object:

@MarkBennett
MarkBennett / gist:5701278c47c1567d915856995de22c10
Created March 1, 2018 05:16 — forked from scottburton11/gist:3222152
Audio Compression for Voiceover

About compression

Audio compression is used to reduce the dynamic range of a recording. Dynamic range is the difference between the loudest and softest parts of an audio signal. It was originally used to guard against defects when cutting wax and vinyl phonograph records, but generally became useful as a way of increasing the loudness of an audio recording without achieving distortion.

The goal of most compression applications is to increase the amplitude of the softest parts of a recording, without increasing the amplitude of the loudest parts.

Compressor anatomy

Compressors generally all have the same conceptual parts. However, not all compressors present variable controls for all parts to the user. If you don't see all of your compressor's controls here, there's a chance it either has a fixed value (and no control), or is named something else:

Google+ JavaScript Community FAQs

These are frequently asked question in the JavaScript Community.

  1. How do I do thing in Java?

That's a great question! Please find a Java community on Google+ to ask. JavaScript is not the same as Java. Here's a good explanation of the differences between Java and JavaScript: http://www.dannyg.com/ref/javavsjavascript.html.