Skip to content

Instantly share code, notes, and snippets.

@YesThatAllen
YesThatAllen / custom.css
Created October 18, 2014 06:34
discourse CSS
html .social {
text-align: center;
}
a {
border-bottom: 1px dotted gray;
}
a.star {
border-bottom: none;
@YesThatAllen
YesThatAllen / gist:674ef18167494d991597
Created September 29, 2014 02:10
Liteswitch looping logs
9/28/14 9:09:09.887 PM NotificationCenter[1037]: Dock connection interrupted!
9/28/14 9:09:09.887 PM NotificationCenter[1037]: disconnect 0x60800010f150
9/28/14 9:09:09.888 PM NotificationCenter[1037]: Dock connection invalid!
9/28/14 9:09:09.888 PM NotificationCenter[1037]: disconnect 0x0
9/28/14 9:09:09.900 PM com.apple.xpc.launchd[1]: (com.apple.Dock.agent[58574]) Service exited with abnormal code: 1
9/28/14 9:09:09.987 PM WindowServer[216]: Surface testing disallowed updates for 10 sequential attempts...
9/28/14 9:09:09.996 PM WindowServer[216]: Surface test allowed updates after 11 attempts
9/28/14 9:09:10.000 PM kernel[0]: Sandbox: storeuid(1803) deny mach-lookup com.apple.dock.server
9/28/14 9:09:10.000 PM kernel[0]: Sandbox: storeuid(1803) deny mach-lookup com.apple.dock.server
9/28/14 9:09:10.673 PM com.apple.xpc.launchd[1]: (com.apple.imfoundation.IMRemoteURLConnectionAgent) The _DirtyJetsamMemoryLimit key is not available on this platform.
Instructions for clearing expired DigiCert SSL certificate on OSX
NOTICE: The following instructions “worked for me.” Proceed at your own risk.
Symptoms:
* Visiting several sites, such as github, gravatar, twitter’s CDN results in “invalid certificate” errors
* For example: http://i.imgur.com/8gPRfI3.png
## Instructions
@YesThatAllen
YesThatAllen / postflight-add-on.py
Last active June 15, 2017 17:44
Disabling a Watchman Monitoring plugin before first run
#To disable a specific plugin
# Don't.. you probably would rather have the plugin ignored on the server side, so that the data can still be gathered.
@YesThatAllen
YesThatAllen / wm.sh
Last active August 29, 2015 14:02
How to install the Watchman Monitoring agent in four lines
/usr/bin/defaults write /Library/MonitoringClient/ClientSettings ClientGroup -string "Insert_ClientGroup_variable_here" && \
/usr/bin/curl -L --sslv3 https://{subdomain}.monitoringclient.com/downloads/MonitoringClient.pkg > /tmp/MonitoringClient.pkg && \
/usr/sbin/installer -target / -pkg /tmp/MonitoringClient.pkg
/bin/rm /tmp/MonitoringClient.pkg
tester105-vm (172.16.46.105)
total 8
drwxr-xr-x 5 root wheel 170 Dec 28 07:24 .
drwxr-xr-x 6 root wheel 204 Dec 28 07:24 ..
drwxr-xr-x 8 root wheel 272 Dec 28 11:46 2.3
drwxr-xr-x 11 root wheel 374 Dec 28 12:48 2.5
lrwxr-xr-x 1 root wheel 3 Dec 28 07:24 Current -> 2.5
<?php
/*
Plugin Name: Disqus Comment System
Plugin URI: http://disqus.com/
Description: The Disqus comment system replaces your WordPress comment system with your comments hosted and powered by Disqus. Head over to the Comments admin page to set up your DISQUS Comment System.
Author: Disqus <team@disqus.com>
Version: 2.74
Author URI: http://disqus.com/
*/
@YesThatAllen
YesThatAllen / rake.rb
Last active December 15, 2020 13:14
Rake tasks in Discourse as of April 13, 2017
# /var/discourse# ./launcher enter app
# RAILS_ENV=production bundle exec rake -T
rake about # List versions of all Rails frameworks and the environment
rake add_topic_to_quotes # Add the topic to quotes
rake admin:create # Creates a forum administrator
rake admin:invite[email] # invite an admin to this discourse instance
rake api_key:get # generate api key if missing, return existing if already there
rake assets:clean[keep] # Remove old compiled assets
rake assets:clobber # Remove compiled assets
@YesThatAllen
YesThatAllen / gist:8382519
Created January 12, 2014 09:10
errors from a newbie running Discourse on a 10.9.1 box
Finished in 4 minutes 14.5 seconds
3367 examples, 26 failures
Failed examples:
rspec ./spec/controllers/list_controller_spec.rb:29 # ListController indexes allows users to filter on a set of topic ids
rspec ./spec/models/topic_spec.rb:1202 # Topic for_digest returns regular topics
rspec ./spec/models/topic_spec.rb:773 # Topic revisions changing category removing a category creates a new revision
rspec ./spec/models/topic_spec.rb:882 # Topic change_category with a previous category when the category exists resets the category
rspec ./spec/models/topic_spec.rb:803 # Topic change_category without a previous category should not change the topic_count when not changed
@YesThatAllen
YesThatAllen / gist:8328404
Created January 9, 2014 02:25
nginx conf used to host our discourse community, where any http request is moved to https for delivery
# Additional MIME types that you'd like nginx to handle go in here
types {
text/csv csv;
}
upstream discourse {
server unix:/var/www/discourse/tmp/sockets/thin.0.sock;
server unix:/var/www/discourse/tmp/sockets/thin.1.sock;
server unix:/var/www/discourse/tmp/sockets/thin.2.sock;
server unix:/var/www/discourse/tmp/sockets/thin.3.sock;