Skip to content

Instantly share code, notes, and snippets.

View ceelsoin's full-sized avatar
🏠
Working from home

Celso Inácio ceelsoin

🏠
Working from home
View GitHub Profile
@ceelsoin
ceelsoin / package.json
Last active December 26, 2019 16:23
arquitetura-limpa-node-typescript-medium
{
"name": "blog-service",
"version": "1.0.0",
"main": "server.js",
"scripts": {
"test": "jest",
"dev": "nodemon --watch \"src/\" --exec \"ts-node src/server.ts\" -e ts",
"build": "rm -r -f ./dist && tsc && cp package.json ./dist/package.json && cp .env ./dist/.env"
},
"dependencies": {
2020-02-11 21:33:37.361 26006-26036/com.cdnbye.cdnbye_example I/flutter: [Instance of 'StreamCategories', Instance of 'StreamCategories', Instance of 'StreamCategories', Instance of 'StreamCategories', Instance of 'StreamCategories', Instance of 'StreamCategories', Instance of 'StreamCategories', Instance of 'StreamCategories', Instance of 'StreamCategories', Instance of 'StreamCategories', Instance of 'StreamCategories', Instance of 'StreamCategories', Instance of 'StreamCategories', Instance of 'StreamCategories', Instance of 'StreamCategories', Instance of 'StreamCategories', Instance of 'StreamCategories', Instance of 'StreamCategories', Instance of 'StreamCategories', Instance of 'StreamCategories', Instance of 'StreamCategories', Instance of 'StreamCategories', Instance of 'StreamCategories', Instance of 'StreamCategories', Instance of 'StreamCategories']
2020-02-11 21:33:48.394 26006-26036/com.cdnbye.cdnbye_example I/flutter: Original URL: http://tv.minhalista.me/live/rubenstest5000/rubenstest5001/3709
@ceelsoin
ceelsoin / README.md
Last active March 30, 2020 18:27 — forked from mosquito/README.md
Add mariadb or other docker-compose as a systemd unit

MariaDB (or others) Docker compose as a systemd unit

Install docker-compose

sudo curl -L "https://github.com/docker/compose/releases/download/1.23.1/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
sudo chmod +x /usr/local/bin/docker-compose
docker-compose --version
@ceelsoin
ceelsoin / students.py
Created May 24, 2020 18:27
Mentoria hackingrio
import sqlite3
conn = sqlite3.connect('estudantes.db')
cursor = conn.cursor()
cursor.execute('''
CREATE TABLE IF NOT EXISTS students(
UserID VARCHAR(20) NOT NULL,
username VARCHAR(60) NOT NULL,
firstname VARCHAR(60) NOT NULL,
email VARCHAR(60) NOT NULL,
#!/bin/bash
#Backup_Directory_Locations
BACKUPROOT="/var/www/backups_diarios"
TSTAMP=$(date +"%d-%b-%Y-%H:%M")
S3BUCKET="approvedemailplatformsso-${domain}"
TSTAMP=$(date +"%d-%b-%Y-%H:%M")
zip -r /var/www/backups_diarios/$TSTAMP.html.zip /var/www/html/
# Move file from server to your S3 bucket
@ceelsoin
ceelsoin / bench.js
Created August 17, 2020 13:47 — forked from billywhizz/bench.js
node.js static file serving benchmark
var TCP = process.binding("tcp_wrap").TCP;
var Buffer = process.binding("buffer").SlowBuffer;
var HTTPParser = process.binding("http_parser").HTTPParser;
function setupSocket(peer) {
function shutdownHandler(status, handle, req) {
// TODO: ensure we only shutdown once
if(status != 0) {
if(peer.onerror) {
var err = new Error("shutdown");
@ceelsoin
ceelsoin / index.js
Created August 24, 2020 14:59 — forked from akexorcist/index.js
Axios post method requesting with x-www-form-urlencoded content type
const axios = require('axios')
const qs = require('querystring')
...
const requestBody = {
name: 'Akexorcist',
age: '28',
position: 'Android Developer',
description: 'birthdate=25-12-1989&favourite=coding%20coding%20and%20coding&company=Nextzy%20Technologies&website=http://www.akexorcist.com/',
@ceelsoin
ceelsoin / android_instructions.md
Created November 3, 2020 18:10 — forked from patrickhammond/android_instructions.md
Easily setup an Android development environment on a Mac

Here is a high level overview for what you need to do to get most of an Android environment setup and maintained.

Prerequisites (for Homebrew at a minimum, lots of other tools need these too):

  • XCode is installed (via the App Store)
  • XCode command line tools are installed (xcode-select --install will prompt up a dialog)
  • Java

Install Homebrew:

ruby -e "$(curl -fsSL https://raw.github.com/Homebrew/homebrew/go/install)"

@ceelsoin
ceelsoin / README.md
Created January 5, 2021 17:03
Remove chrome autofill blue background css trick

Autofill remove css trick

  • Just add this css on your form page.

(All forms cotinue autofilling, this css just remove blue background)

public async getKeycloakUserByEmail(email: String): Promise<any> {
const config = {
headers: {
Authorization: 'Bearer '+ await this.getApplicationServiceToken(),
}
};
return axios.get(`${this.BASE_URL}/auth/admin/realms/shallwe/users?email=${email}`, config)
}