Skip to content

Instantly share code, notes, and snippets.

View ecoidealist's full-sized avatar

Katie Stevens ecoidealist

View GitHub Profile
if ( is_admin() && function_exists( 'crocoblock_wizard' ) ) {
crocoblock_wizard()->settings->register_external_config( array(
'import' => array(
'chunk_size' => 10,
'regenerate_chunk_size' => 1,
'allow_types' => false,
),
) );
}
rem Or even better, create a system image!
rem http://www.aomeitech.com/ab/standard.html
rem https://www.macrium.com/reflectfree
rem Things, that will get broken, that will get noticed ASAP or after restart, like Start or WiFi for sure!
rem Disabling network services (Dhcp/NlaSvc/netprofm/nsi/RmSvc) will prevent you from managing network settings!
rem Windows Defender Firewall is set to block all inbound/outbound except allowed apps, which have to be added first!
rem Terminating "ShellExperienceHost.exe" will restart it and Start's functionality
rem You can create a task, which runs after logon with one minute delay.
@tanaikech
tanaikech / submit.md
Last active January 5, 2025 05:58
Retrieving Screen Shots of Sites using Google Apps Script

Retrieving Screen Shots of Sites using Google Apps Script

This is a sample script for retrieving screen shots of sites using Google Apps Script. In order to retrieve the screen shot, here, I used PageSpeed API.

When you use this, please copy and paste the following script, and set an URL you want to retrieve a screen shot.

var siteUrl = "### URL you want to retrieve a screen shot. ###";
var url =
  "https://www.googleapis.com/pagespeedonline/v4/runPagespeed?screenshot=true&fields=screenshot&url=" +
 encodeURIComponent(siteUrl);
@erictherobot
erictherobot / gist:0963b08a3d3383183b83593f06e19e1c
Created March 25, 2018 18:34
Government Contracting Acronyms
8(a) Section 8 (a) of the Small Business Act; Federal Contracting Preference Program for Disadvantaged Businesses
AAR After Action Report
ACAT Acquisition Category
ACO Administrative Contracting Officer
ACQ Acquisition
ACS Assistant Chief of Staff
ACWP Actual Cost of Work Performed
ADA Americans with Disabilities Act
ADPE Automated Data Processing Equipment
let fetch = require('node-fetch');
let url = 'https://picsum.photos/list';
fetch(url)
.then(response=>response.json())
.then(data=>{
console.log(data.length);
console.log(data[0].format);
console.log(data[0].width);
console.log(data[0].height);
We can't make this file beautiful and searchable because it's too large.
pattern,cnt
^,1657
-$,376
--,355
root.*/file.*\n,348
(?m)^hello world,338
\s+,296
\s*,278
^[a-z],275
[cg]pu,245
@steren
steren / regexp-github.sql
Last active July 13, 2020 17:49
Extract constant Go regular expressions from GitHub
# Extracts constant Go regular expressions from GitHub
# using BigQuery GitHub public dataset.
# To run on the entire GitHub corpus,
# remove the `sample_` prefix from the table names.
# Warning: This query processes ~2.2 TB of data, which is above BigQuery free quota.
SELECT
REGEXP_EXTRACT(pattern, r'^[\"\`](.*)[\"\`]$') as pattern,
COUNT(*) AS cnt,
FROM (
SELECT
@tktD
tktD / 20141211_AEDmap.geojson
Created July 20, 2017 08:03
AEDマップを置いてみました。
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@tommorris
tommorris / ical_test.md
Last active November 2, 2019 12:14
iCalendar test documentation

iCalendar TZ testing

The following iCalendar snippet works in Fantastical and Calendar.app

BEGIN:VCALENDAR
BEGIN:VEVENT
SUMMARY:Test Event
DTSTART;TZID=America/Los_Angeles:20160630T120000

Most downloaded projects

SELECT
  file.project,
  COUNT(*) as total_downloads,
FROM
  TABLE_DATE_RANGE(
    [the-psf:pypi.downloads],
    TIMESTAMP("20160114"),