Skip to content

Instantly share code, notes, and snippets.

View johnbocook's full-sized avatar
💯
I come here for the dark theme.

John Bocook johnbocook

💯
I come here for the dark theme.
View GitHub Profile
@johnbocook
johnbocook / interview-questions.md
Created April 22, 2023 02:50 — forked from jvns/interview-questions.md
A list of questions you could ask while interviewing

A lot of these are outright stolen from Edward O'Campo-Gooding's list of questions. I really like his list.

I'm having some trouble paring this down to a manageable list of questions -- I realistically want to know all of these things before starting to work at a company, but it's a lot to ask all at once. My current game plan is to pick 6 before an interview and ask those.

I'd love comments and suggestions about any of these.

I've found questions like "do you have smart people? Can I learn a lot at your company?" to be basically totally useless -- everybody will say "yeah, definitely!" and it's hard to learn anything from them. So I'm trying to make all of these questions pretty concrete -- if a team doesn't have an issue tracker, they don't have an issue tracker.

I'm also mostly not asking about principles, but the way things are -- not "do you think code review is important?", but "Does all code get reviewed?".

/* You can use @media or link to a seperate print stylesheet
<link rel="stylesheet" href="global.css">
<link rel="stylesheet" href="print.css" media="print">
<link rel="stylesheet" href="specific.css" media="type and (feature)">
<link rel="stylesheet" href="landscape.css" media="(orientation: landscape)">
<link rel="stylesheet" href="portrait.css" media="(orientation: portrait)">
*/
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no" />
<meta name="description" content="A description of the page" />
<meta name="author" content="Author Name" />
<link rel="icon" type="image/x-icon" href="/fav/icon/location/name.ico" />
# Example 1: Block only Googlebot
User-agent: Googlebot
Disallow: /
# Example 2: Block Googlebot and Adsbot
User-agent: Googlebot
User-agent: AdsBot-Google
Disallow: /
# Example 3: Block all crawlers except AdsBot (AdsBot crawlers must be named explicitly)
@johnbocook
johnbocook / imageAdjustFilters.css
Created December 9, 2022 13:38
Css filters to adjust the look of a png file.
/*Filter styles*/
.saturate { filter: saturate(3); }
.grayscale { filter: grayscale(100%); }
.contrast { filter: contrast(160%); }
.brightness { filter: brightness(0.25); }
.blur { filter: blur(3px); }
.invert { filter: invert(100%); }
.sepia { filter: sepia(100%); }
.huerotate { filter: hue-rotate(180deg); }
<?php
return [
'dsn' => 'mysql:host=localhost;dbname=fanatos',
'username' => 'root',
'password' => 'root',
];
<?php
return [
'xsolla' => [
'api_key' => null,
'merchant_id' => null,
'project_id' => null,
'project_key' => null,
],
];
@johnbocook
johnbocook / SonisSlack.cfm
Created September 28, 2017 06:53
Proof of concept - interacting with our SIS via slack channels. Includes authentication check based on channel access.
<cfoutput>
<cfif #StructKeyExists(FORM, "token")#>
<cfif #FORM.token# NEQ '##############'>
Sorry, Authentication Failed
<cfelse>
<cfif #FORM.channel_id# NEQ "############">
What are you doing?!?!!?? This channel is not authenticated - stop trying to break stuff.
<cfelse>
<cfif #FORM.text# EQ "restart">
@#FORM.user_name# - Sonis is restarting
@johnbocook
johnbocook / LunchBot.cfm
Created September 28, 2017 06:50
LunchBot is a little slack integration that randomly chooses where to have lunch.
<cfoutput>
<cfif #StructKeyExists(FORM, "token")#>
<cfif #FORM.token# NEQ '#PUBLICKEY##'>
Sorry, Authentication Failed
<cfelse>
<cfset resturants = "BW3, Roosters, Wendys, Gibbys, Tuscan Table, El Palmor, Goodwins Family
Resturant, Cardo's Pizza, Zanzy's Pizza, High Court Cafe, Arby's, Grand Buffett, McDonalds, KFC, Richie's New York Corner Deli, ">
<cfset objRandomReport=ArrayNew(1)>
@johnbocook
johnbocook / AD-Search.ps1
Last active March 16, 2021 07:14
Powershell Active Directory Search
$username = Read-Host -Prompt 'Type in the username:?'
csvde -f searchAD.txt -p subtree -l "sAMAccountName,cn,distinguedName" -r "(&(objectClass=User)(sAMAccountName=$username))"
Import-Csv .\searchAD.txt | Out-GridView -Title "Active Directory"