Skip to content

Instantly share code, notes, and snippets.

View sylar's full-sized avatar
:shipit:
No.

Andrei Constantinescu sylar

:shipit:
No.
View GitHub Profile
/* preventScrollWhenSoftKeyboardAppearsIfThereIsPlentyOfRoom(event)
*
* Attach this handler to `touchstart` on any UI control that brings up the keyboard when you don't want iOS
* MobileSafari to scroll when a user taps it. Assumes that the input is near the top of the page and the user has
* not scrolled down (specific to my case, sorry!)
*
* requires top-level CSS directives so we can add it to the body:
* ```
* .prevent-ios-focus-scrolling {
* position: fixed;

Setting up a Github Pages Project Page with Circle CI

Greetings! This will guide you through a basic setup of a Github pages project with Circle CI. All examples here are meant to be as clear as possible - there may be different and quicker ways to do some of these things, but this tutorial is biased on the side of clarity rather than brevity.

Setting up Github Pages with a project

You need a Github repo with an index.html file in it (for an example, check out My personal website. This tutorial assumes you have merge permissions with the repo.

Now, check out this repository to your workstation and create a new gh-pages branch.

@benkulbertis
benkulbertis / cloudflare-update-record.sh
Last active April 28, 2024 16:35
Cloudflare API v4 Dynamic DNS Update in Bash
#!/bin/bash
# CHANGE THESE
auth_email="user@example.com"
auth_key="c2547eb745079dac9320b638f5e225cf483cc5cfdda41" # found in cloudflare account settings
zone_name="example.com"
record_name="www.example.com"
# MAYBE CHANGE THESE
ip=$(curl -s http://ipv4.icanhazip.com)