- Fork the repo
- Clone the repo
git checkout -b NEW_BRANCH
git remote add upstream ORIGINAL_REPO_URL
- Make changes
- Commit and push changes
- Open your repo on Github
- Click Compare & pull request
- Enter description
- Click Create pull request
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function parseEmojis(str) { | |
return str.match(/(?:[\u2700-\u27bf]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff])[\ufe0e\ufe0f]?(?:[\u0300-\u036f\ufe20-\ufe23\u20d0-\u20f0]|\ud83c[\udffb-\udfff])?(?:\u200d(?:[^\ud800-\udfff]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff])[\ufe0e\ufe0f]?(?:[\u0300-\u036f\ufe20-\ufe23\u20d0-\u20f0]|\ud83c[\udffb-\udfff])?)*/); | |
} |
A somewhat niche problem is opening a centered popup window when you have multiple monitors. One you case you might encounter for this is opening a Twitter Web Intent window, which creates a tweet for a user to post. Here is their recomended code for opening a Web Intent popup:
(function() {
if (window.__twitterIntentHandler) return;
var intentRegex = /twitter\.com\/intent\/(\w+)/,
windowOptions = 'scrollbars=yes,resizable=yes,toolbar=no,location=yes',
width = 550,
height = 420,
winHeight = screen.height,
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0"?> | |
<configuration> | |
<system.webServer> | |
<rewrite> | |
<rules> | |
<rule name="React Routes" stopProcessing="true"> | |
<match url=".*" /> | |
<conditions logicalGrouping="MatchAll"> | |
<add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" /> | |
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" /> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
makemkvcon [options] Command Parameters | |
General options: | |
--messages=file | |
Output all messages to file. Following special file names are recognized: | |
-stdout - stdout | |
-stderr - stderr | |
-null - disable output | |
Default is stdout |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Usage: HandBrakeCLI [options] -i <source> -o <destination> | |
General Options -------------------------------------------------------------- | |
-h, --help Print help | |
--version Print version | |
--json Log title, progress, and version info in | |
JSON format | |
-v, --verbose[=number] Be verbose (optional argument: logging level) | |
-Z. --preset <string> Select preset by name (case-sensitive) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8"?> | |
<profile> | |
<!-- profile name --> | |
<name lang="eng">AAC-stereo</name> | |
<!-- Common MKV flags --> | |
<mkvSettings | |
ignoreForcedSubtitlesFlag="true" | |
useISO639Type2T="false" | |
setFirstAudioTrackAsDefault="true" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function getNumberWithOrdinal(n) { | |
const s = ["th", "st", "nd", "rd"]; | |
const v = n % 100; | |
return n + (s[(v - 20) % 10] || s[v] || s[0]); | |
} |
Borrowed from wprig
Some applications that interact with git repos will provide a user interface for squashing. Refer to your application's document for more information.
If you're familiar with Terminal, you can do the following:
- Make sure your branch is up to date with the master branch.
- Run
git rebase -i master
.