Skip to content

Instantly share code, notes, and snippets.

Janos Gyerik janosgyerik

Block or report user

Report or block janosgyerik

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile


Lorem ipsum dolor sid amet.


Lorem ipsum dolor sid amet.


provider "google" {
region = "${var.region}"
project = "${var.project_name}"
credentials = "${file("${var.credentials_file_path}")}"
resource "google_compute_instance" "docker" {
count = 1
google_compute_instance.docker[0]: Creating...
google_compute_instance.docker[0]: Still creating... [10s elapsed]
google_compute_instance.docker[0]: Still creating... [20s elapsed]
google_compute_instance.docker[0]: Provisioning with 'remote-exec'...

Error: Failed to parse ssh private key: ssh: cannot decode encrypted private keys
// solution to: 732. My Calendar III
class MyCalendarThree {
private final Comparator<Pos> comparator = Comparator.<Pos>comparingInt(p -> p.pos)
.thenComparing((p1, p2) -> {
if (p1.mark == p2.mark) return, p2.hashCode());
if (p1.mark == Mark.END) return -1;
return 1;
private final SortedSet<Pos> marks = new TreeSet<>(comparator);
View Install & Configure

Create Amazon EC2 Instance

  • Ensure that inbound MySQL port 3306 is opened
  • chmod 700 "keypair-name.pem"

Install MySQL

To install MySQL, run the following command from a terminal prompt:

  • sudo apt-get install mysql-server
View twitter-followers.R
D <- c()
for(u in c("OneNaziq", "AzimRidzuan_", "pais_10")) {
D <- rbind(D, get_followers(u, n= "all", page = "-1", parse = TRUE, as_double = FALSE, token = NULL))


public Response createPost(@FormParam("type") String type,  @FormParam("content") String content) { 
    postEJB.createPostUserRest(type, content);
    URI userURI = uriInfo.getAbsolutePathBuilder().build();
    return Response.created(userURI).build();

Watch or unwatch GitHub repositories using GitHub API + curl + jq + Bash

When you need to perform an operation on a large number of GitHub repositories, their REST API and some command line magic comes in handy. This short talk will demonstrate a technique to watch and unwatch GitHub repositories using ad-hoc scripts. The example should give a good idea how to perform other bulk operations too.


I have this setting in my personal GitHub account:

You can’t perform that action at this time.