- Related Setup: https://gist.github.com/hofmannsven/6814278
- Related Pro Tips: https://ochronus.com/git-tips-from-the-trenches/
- Interactive Beginners Tutorial: http://try.github.io/
- Git Cheatsheet by GitHub: https://services.github.com/on-demand/downloads/github-git-cheat-sheet/
| #Steps to merge/close pull requests with two main branches | |
| As NiFi now has a 1.0 (master) and 0.x (support) branch, pull requests (PR) must be applied to both. Here is a step-by-step guide for committers to ensure this occurs for all PRs. | |
| 1. Check out the latest master | |
| ``` $ git checkout master | |
| $ git pull upstream master | |
| ``` | |
| 2. Check out the PR (example #327). This will be in `detached-HEAD` state. (Note: You may need to edit the `.git/config` file to add the `fetch` lines [below](#fetch)) |
| #!/bin/sh | |
| git diff --quiet --exit-code | |
| if [ $? -ne 0 ]; then | |
| echo "Cannot run grrr if you have uncommited changes" | |
| exit -1; | |
| fi | |
| current_branch=`git rev-parse --abbrev-ref HEAD` | |
| if [ "$current_branch" == "HEAD" ]; then |
A git choose-your-own-adventure!
This document is an attempt to be a fairly comprehensive guide to recovering from what you did not mean to do when using git. It isn't that git is so complicated that you need a large document to take care or your particular problem, it is more that the set of things that you might have done is so large that different techniques are needed depending on exactly what you have done and what you want to have happen.
Locate the section for your github remote in the .git/config file. It looks like this:
[remote "origin"]
fetch = +refs/heads/*:refs/remotes/origin/*
url = git@github.com:joyent/node.git
Now add the line fetch = +refs/pull/*/head:refs/remotes/origin/pr/* to this section. Obviously, change the github url to match your project's URL. It ends up looking like this:
| # SNAKES GAME | |
| # Use ARROW KEYS to play, SPACE BAR for pausing/resuming and Esc Key for exiting | |
| import curses | |
| from curses import KEY_RIGHT, KEY_LEFT, KEY_UP, KEY_DOWN | |
| from random import randint | |
| curses.initscr() | |
| win = curses.newwin(20, 60, 0, 0) |
| /** | |
| * Module for General utility functions and classes | |
| * @module utils | |
| * | |
| */ | |
| Ext.ns('BlackjackM','BlackjackM.utils', 'BlackjackM.utils.forms'); | |
| /** | |
| * A class which renders and validates a form based on a Ext.data.Model or Model instace |
Be able to control MiLight bulbs with Amazon Alexa via the MiLight Wifi Bridge.
- At least one MiLight Bulb: http://www.limitlessled.com/shop/rgbw-color-led-light-bulb/
| """Support for Flux lights.""" | |
| import logging | |
| import random | |
| ### | |
| # Added for MagicLight hack | |
| import time | |
| from flux_led import BulbScanner, WifiLedBulb | |
| import voluptuous as vol |
| #pragma once | |
| #include "esphome.h" | |
| using namespace esphome; | |
| enum TuyaCmd : uint8_t { | |
| HEARTBEAT = 0x00, | |
| QUERY_PRODUCT = 0x01, | |
| MCU_CONF = 0x02, | |
| WIFI_STATE = 0x03, |