Skip to content

Instantly share code, notes, and snippets.

View claudioacioli's full-sized avatar
💾
Do you remember?

Claudio Acioli claudioacioli

💾
Do you remember?
  • Mercado Na Rede
  • Brasilia
View GitHub Profile
@claudioacioli
claudioacioli / .tmux.conf
Created March 23, 2021 00:24
Change prefix of tmux
# remap prefix from 'C-b' to 'C-a'
unbind C-b
set-option -g prefix C-a
bind-key C-a send-prefix
# Start window numbering at 1
set -g base-index 1
# with is the better approuch to open and close files
with open('dogs.txt') as reader:
for line in reader:
print(line, end='') #end parameter change the last character of the line
# iterate for reader, line by line is more effecitily
@claudioacioli
claudioacioli / spin-button.html
Created November 6, 2020 02:33
Spin Button with only CSS
<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1">
<style>
.button {
border-radius: 4px;
text-align: center;
padding: 1em;
transition: all 0.5s;
@claudioacioli
claudioacioli / index.html
Created November 5, 2020 02:40
Pure CSS Submitting button
<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1">
<style>
.button {
border-radius: 4px;
text-align: center;
padding: 1em;
transition: all 0.5s;
@claudioacioli
claudioacioli / client.js
Last active March 29, 2020 15:07
RefreshToken
var express = require("express");
var request = require("sync-request");
var url = require("url");
var qs = require("qs");
var querystring = require('querystring');
var cons = require('consolidate');
var randomstring = require("randomstring");
var __ = require('underscore');
__.string = require('underscore.string');
<!doctype html>
<html>
<head>
<title>Flexbox example page</title>
<link href="teste.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div class="container">
<header>
<h1>Ink</h1>
@claudioacioli
claudioacioli / .vimrc
Last active April 14, 2020 00:39
Vim
"Gerenciadores de Plugin
call plug#begin()
Plug 'arcticicestudio/nord-vim'
call plug#end()
execute pathogen#infect()
"Tamanho da identacao
set tabstop=2
"Desativa quebra de linha
set nowrap
"Apresenta numero de linhas
@claudioacioli
claudioacioli / app.py
Created March 14, 2020 17:24
An example on how to reload Flask app in runtime
"""
This is an example on how to reload Flask app in runtime
It can be useful for the use case where you want to enable/disable blueprints/routes dynamically.
To run the app:
> pip install flask & python app.py
Then test it via curl

To start docker deamon istalled with snap on Ubuntu

sudo snap start docker

reference link