Skip to content

Instantly share code, notes, and snippets.

View z0lope0z's full-sized avatar

Lope Chupijay Emano z0lope0z

View GitHub Profile
@maciekish
maciekish / resetXcode.sh
Created August 10, 2016 10:13
Reset Xcode. Clean, clear module cache, Derived Data and Xcode Caches. You can thank me later.
#!/bin/bash
killall Xcode
xcrun -k
xcodebuild -alltargets clean
rm -rf "$(getconf DARWIN_USER_CACHE_DIR)/org.llvm.clang/ModuleCache"
rm -rf "$(getconf DARWIN_USER_CACHE_DIR)/org.llvm.clang.$(whoami)/ModuleCache"
rm -rf ~/Library/Developer/Xcode/DerivedData/*
rm -rf ~/Library/Caches/com.apple.dt.Xcode/*
open /Applications/Xcode.app
@leonardofed
leonardofed / README.md
Last active May 3, 2024 01:24
A curated list of AWS resources to prepare for the AWS Certifications


A curated list of AWS resources to prepare for the AWS Certifications

A curated list of awesome AWS resources you need to prepare for the all 5 AWS Certifications. This gist will include: open source repos, blogs & blogposts, ebooks, PDF, whitepapers, video courses, free lecture, slides, sample test and many other resources.


@marioosh
marioosh / ChatRoom.scala
Last active March 1, 2020 08:11
websocket based on akka-http
class ChatRoom(roomId: Int, actorSystem: ActorSystem) {
private[this] val chatRoomActor = actorSystem.actorOf(Props(classOf[ChatRoomActor], roomId))
def websocketFlow(user: String): Flow[Message, Message, _] = ???
def sendMessage(message: ChatMessage): Unit = chatRoomActor ! message
}
@JohNan
JohNan / QuickReturnRecyclerView.java
Created November 12, 2014 15:38
A simple RecyclerView where a Quick Return view can be added either at the top or the bottom. Inspired by https://github.com/LarsWerkman/QuickReturnListView
import android.content.Context;
import android.os.Build;
import android.support.v7.widget.RecyclerView;
import android.util.AttributeSet;
import android.view.Gravity;
import android.view.View;
import android.view.ViewGroup;
import android.view.animation.TranslateAnimation;
import android.widget.FrameLayout;
@jooyunghan
jooyunghan / Main.java
Created July 14, 2014 09:09
Retrofit + RxJava in Java
package com.company;
import retrofit.RestAdapter;
import retrofit.http.GET;
import retrofit.http.Path;
import rx.Observable;
import rx.Subscriber;
import rx.functions.Action1;
import rx.functions.Func1;
import rx.functions.Func2;
@rivol
rivol / Util.java
Last active November 29, 2017 06:54
get retrofit error response's body
package com.gateme3.app.util;
import android.location.Location;
import android.location.LocationManager;
import android.util.Log;
import com.gateme3.app.db.PurchasedItem;
import com.gateme3.app.db.Venue;
import java.io.ByteArrayOutputStream;
@pongstr
pongstr / Globe4gLTE.md
Last active October 3, 2023 05:39
Access to Globe Broadband's Azatech DSL5001EN Router

Globe 4G LTE (Internet Only)

Noob access to administer your local area network and wifi access:

http://192.168.254.254

username: user
password: @l03e1t3
@dannguyen
dannguyen / aws-write-to-s3-acl.rb
Created April 17, 2013 18:06
Using Ruby AWS-SDK to write an object to S3 and set its ACL
#!/usr/bin/ruby
require 'rubygems'
require 'aws-sdk'
#creates an interface object to AWS S3
AWS.config( :access_key_id => '' , :secret_access_key => '' )
#creates an interface to the S3
s3interface = AWS::S3.new
@emil2k
emil2k / Connectivity.java
Last active December 22, 2023 06:03
Android utility class for checking device's network connectivity and speed.
/*
* Copyright (c) 2017 Emil Davtyan
*
* Permission is hereby granted, free of charge, to any person obtaining
* a copy of this software and associated documentation files (the
* "Software"), to deal in the Software without restriction, including
* without limitation the rights to use, copy, modify, merge, publish,
* distribute, sublicense, and/or sell copies of the Software, and to
* permit persons to whom the Software is furnished to do so, subject to
* the following conditions:
@rgreenjr
rgreenjr / postgres_queries_and_commands.sql
Last active May 3, 2024 16:53
Useful PostgreSQL Queries and Commands
-- show running queries (pre 9.2)
SELECT procpid, age(clock_timestamp(), query_start), usename, current_query
FROM pg_stat_activity
WHERE current_query != '<IDLE>' AND current_query NOT ILIKE '%pg_stat_activity%'
ORDER BY query_start desc;
-- show running queries (9.2)
SELECT pid, age(clock_timestamp(), query_start), usename, query
FROM pg_stat_activity
WHERE query != '<IDLE>' AND query NOT ILIKE '%pg_stat_activity%'