Skip to content

Instantly share code, notes, and snippets.

View edufolly's full-sized avatar

Eduardo Folly edufolly

View GitHub Profile
@koch-uchi
koch-uchi / postgres_queries_and_commands.sql
Created May 14, 2020 21:05 — forked from rgreenjr/postgres_queries_and_commands.sql
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%'
@atothek1
atothek1 / osx_bootstrap.sh
Created May 14, 2020 11:32 — forked from codeinthehole/osx_bootstrap.sh
Script to install stuff I want on a new OSX machine
#!/usr/bin/env bash
#
# Bootstrap script for setting up a new OSX machine
#
# This should be idempotent so it can be run multiple times.
#
# Some apps don't have a cask and so still need to be installed by hand. These
# include:
#
# - Twitter (app store)
@anish-kr07
anish-kr07 / gist:2a5fbebc20a21a9cf06ab9dbaeaefe87
Last active May 16, 2020 00:02 — forked from vasanthk/System Design.md
System Design Cheatsheet
We couldn’t find that file to show.
@aalmiray
aalmiray / DataSourceConfig.java
Last active February 25, 2021 07:41
SpringBoot + Oracle JDBC
package com.acme.ucp;
import oracle.ucp.jdbc.PoolDataSource;
import oracle.ucp.jdbc.PoolDataSourceFactory;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Primary;
import javax.sql.DataSource;
@SalomonBrys
SalomonBrys / Stadia-ubuntu.md
Last active February 15, 2023 17:48
Stadia in Ubuntu

Stadia in Ubuntu

1. Install Chromium-vaapi & drivers

  • Add the chromium-vaapi dev repository:
    sudo add-apt-repository ppa:saiarcot895/chromium-beta
    sudo apt-get update
    
  • Install Chromium-vaapi:
@sherifabdlnaby
sherifabdlnaby / Dockerfile
Created May 13, 2020 22:01
Elasticsearch Base Dockerfile
# https://github.com/elastic/elasticsearch-docker
FROM docker.elastic.co/elasticsearch/elasticsearch:7.6.2
# Add your elasticsearch plugins setup here
# Example: RUN elasticsearch-plugin install analysis-icu
#RUN elasticsearch-plugin install --batch repository-s3
@FurkanKozen
FurkanKozen / FindingKeyByItsValue.cs
Created May 13, 2020 21:52
Finding the key by its value
using System;
using System.Linq;
using System.Collections.Generic;
class Program
{
public static void Main(string[] args)
{
var dict = new Dictionary<string, int>();
dict.Add("A", 25);
@viniciusdaniel
viniciusdaniel / google-hacking-techniques.md
Last active November 27, 2023 19:46
COPY - Exploring Google Hacking Techniques
@Cactam
Cactam / PY0101EN-2-4-Sets.ipynb
Created May 12, 2020 22:25
Created on Skills Network Labs
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@dray89
dray89 / yahoo_statistics.py
Last active January 18, 2023 00:07
Python Scrape Yahoo Stock Market Statistics Webpage
import pandas as pd
import numpy as np
from bs4 import BeautifulSoup
import requests, lxml
from lxml import html
class statistics: