Skip to content

Instantly share code, notes, and snippets.

View ppremk's full-sized avatar
🌷
on a git high..

Prem Kumar Ponuthorai ppremk

🌷
on a git high..
View GitHub Profile
@zeke
zeke / whatchanged.sh
Created May 8, 2020 03:07
git command for creating a diff of recent changes on a specific path (in this case, `content/v3`)
# print output in a manpage-style pager
git whatchanged --since="1 week ago" -p content/v3
# pipe it to stdout
git whatchanged --since="1 week ago" -p content/v3 | cat
# pipe to a file and open that file in an editor
# (vscode highlights diffs, atom does not without a plugin)
git whatchanged --since="1 week ago" -p content/v3 > diff.sh && $EDITOR diff.sh
@petrsvihlik
petrsvihlik / GitHub-GraphQL-PowerBI.m
Last active February 16, 2024 17:16
Loading GraphQL data (GitHub API v4) into PowerBI
// This script shows how to use M language (Power Query Formula Language)
// to read data from GitHub API v4 using a POST request.
// This can come in handy when building PowerBI reports that utilize GraphQL endpoints for loading data.
let
vUrl = "https://api.github.com/graphql",
vHeaders =[
#"Method"="POST",
#"Content-Type"="application/json",
#"Authorization"="Bearer <your_personal_token_here>"
@primetheus
primetheus / docker_svn-server.md
Last active December 27, 2023 10:34 — forked from dpmex4527/docker_svn-server.md
Set up SVN server on docker
@markerikson
markerikson / redux-thunk-examples.js
Last active September 4, 2022 11:12
Redux-Thunk examples
// The classic AJAX call - dispatch before the request, and after it comes back
function myThunkActionCreator(someValue) {
return (dispatch, getState) => {
dispatch({type : "REQUEST_STARTED"});
myAjaxLib.post("/someEndpoint", {data : someValue})
.then(
response => dispatch({type : "REQUEST_SUCCEEDED", payload : response}),
error => dispatch({type : "REQUEST_FAILED", error : error})
);
@anythingcodes
anythingcodes / google-form-to-github-issue.md
Last active March 22, 2024 18:53
Generate GitHub Issue from Google Form submission

Generate GitHub Enterprise Issue from Google Form submission

To generate a nicely-formatted GitHub issue (even for GitHub Enterprise accounts) from a Google Form submission, you can use Google's script editor along with a GitHub personal access token that connects to the API. This is particularly useful when you need to triage bugs or feature requests directly to developers, but those who are submitting issues do not have access to your GitHub Enterprise instance.

Once this is up and running, on the development end, you can do some cool things within the body of each issue, like automatically closing GitHub issues via your commit messages and CCing your dev group or individual team members for each issue.

Here's how to set it up.

Step 1: Create Your Form

  • Go to Google Drive and create a form with fields
  • Click the Responses tab
@subfuzion
subfuzion / curl.md
Last active May 6, 2024 02:31
curl POST examples

Common Options

-#, --progress-bar Make curl display a simple progress bar instead of the more informational standard meter.

-b, --cookie <name=data> Supply cookie with request. If no =, then specifies the cookie file to use (see -c).

-c, --cookie-jar <file name> File to save response cookies to.

@bmcbride
bmcbride / google-form-to-github-issue.md
Last active April 5, 2024 15:47
Create a new GitHub Issue from a Google Form submission

Wiring up a Google Form to GitHub is not that difficult with a little bit of Apps Script automation. All you need is a Google account, a GitHub account, and a web browser...

Set up your GitHub Personal Access Token

Personal access tokens provide an easy way to interact with the GitHub API without having to mess with OAuth. If you don't already have a personal access token with repo or public_repo access, visit your GitHub settings page and generate a new token.

Be sure to copy your token some place safe and keep it secure. Once generated, you will not be able to view or copy the token again.

Set up the Form & Spreadsheet

  1. Create a Google Form.
@barrysteyn
barrysteyn / svn-to-git.md
Last active December 26, 2022 22:32
Migrate From SVN To GIT