Skip to content

Instantly share code, notes, and snippets.

View gilly7's full-sized avatar
🎯
Focusing

Gilbert Ng'eno gilly7

🎯
Focusing
View GitHub Profile
@dblevins
dblevins / Dates.java
Last active May 28, 2022 20:02
Works for Java 8 and above. For Java 7 and before, see this legacy version https://gist.github.com/dblevins/03df3cd5eb12f2da05997eef80ac4eca
import java.time.LocalDate;
import java.time.ZoneId;
import java.time.format.DateTimeFormatter;
import java.util.Date;
/**
* This pattern has the following benefits:
*
* - Date formats are referenced as a strong type
* - Code completion on patterns
@developer1622
developer1622 / postman.json
Created January 2, 2022 09:20
Postman collection for Basic REST API on contact
{
"info": {
"_postman_id": "047925bc-b6fe-4581-9d0c-8d8c10061cb2",
"name": "Contacts",
"schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json"
},
"item": [
{
"name": "Index of the server",
"request": {
@gilly7
gilly7 / Contributing.md
Created October 22, 2021 11:32 — forked from MarcDiethelm/Contributing.md
How to contribute to a project on Github

This text now lives at https://github.com/MarcDiethelm/contributing/blob/master/README.md. I turned it into a Github repo so you can, you know, contribute to it by making pull requests.


Contributing

If you want to contribute to a project and make it better, your help is very welcome. Contributing is also a great way to learn more about social coding on Github, new technologies and and their ecosystems and how to make constructive, helpful bug reports, feature requests and the noblest of all contributions: a good, clean pull request.

@michielmulders
michielmulders / post.go
Created December 16, 2020 10:56
Post request Go web server
package main
import (
"log"
"net/http"
"io/ioutil"
)
func postRoute(rw http.ResponseWriter, req *http.Request) {
body, err := ioutil.ReadAll(req.Body)
@jalbam
jalbam / unfollow-non-followers-twitter.js
Last active March 20, 2024 03:15
Code to stop following those ones who are not following you back on Twitter and keeping those you want or follow anyone you want, with certain filters (working in July 2019)
/*
Unfollow (stop following) those people who are not following you back on Twitter (or unfollow everyone if desired).
This will work for new Twitter web site code structure (it was changed from July 2019, causing other unfollow-scripts to stop working).
Instructions:
1) The code may need to be modified depending on the language of your Twitter web site:
* For English language web site, no modification needed.
* For Spanish language web site, remember to set the 'LANGUAGE' variable to "ES".
* For another language, remember to set the 'LANGUAGE' variable to that language and modify the 'WORDS' object to add the words in that language.
@lwiecek
lwiecek / ReversePolishNotation.go
Last active December 14, 2021 11:57
Reverse Polish Notation Calculator in Golang
package main
import (
"fmt"
"strconv"
"strings"
)
func pop2(stack []float64) ([]float64, float64, float64) {
var ab []float64
@alexpchin
alexpchin / Setting_upa_new_repo.md
Last active May 12, 2024 17:06
Create a new repository on the command line

Setting up a new Git Repo

##Create a new repository on the command line

touch README.md
git init
git add README.md
git commit -m "first commit"

git remote add origin git@github.com:alexpchin/.git