Skip to content

Instantly share code, notes, and snippets.

View adrianokerber's full-sized avatar
🏠
Homeoffice

Adriano Kerber adrianokerber

🏠
Homeoffice
View GitHub Profile
{
"$help": "https://aka.ms/terminal-documentation",
"$schema": "https://aka.ms/terminal-profiles-schema",
"actions":
[
{
"command":
{
"action": "copy",
"singleLine": false
using System;
using System.Text;
namespace AdrianoKerber.Converter
{
public static class Base64Converter
{
public static string FromStringToBase64(string stringValue)
{
if (string.IsNullOrWhiteSpace(stringValue))
@adrianokerber
adrianokerber / git-update-fork.sh
Created May 12, 2020 02:14 — forked from rdeavila/git-update-fork.sh
Git: como atualizar um fork com as mudanças do original?
#!/bin/bash
# Adicione um novo remote; pode chamá-lo de "upstream":
git remote add upstream https://github.com/usuario/projeto.git
# Obtenha todos os branches deste novo remote,
# como o upstream/master por exemplo:
git fetch upstream
@adrianokerber
adrianokerber / BRANCHRULES.md
Last active April 3, 2020 13:25 — forked from digitaljhelms/gist:4287848
Git/GitHub branching standards & conventions

Branching

Quick Legend

Description, Instructions, Notes
Instance Branch
@adrianokerber
adrianokerber / settings.json
Last active October 19, 2021 02:20
VSCode settings
{
"workbench.colorTheme": "Dracula",
"editor.fontFamily": "'Fira Code', Consolas, 'Courier New', monospace",
"workbench.iconTheme": "material-icon-theme",
"editor.fontLigatures": true,
"terminal.integrated.shell.windows": "C:\\WINDOWS\\System32\\WindowsPowerShell\\v1.0\\powershell.exe",
"workbench.startupEditor": "newUntitledFile",
"emmet.includeLanguages": {
"javascript": "javascriptreact",
"vue-html": "html",
@adrianokerber
adrianokerber / .hyper.js
Last active May 15, 2019 11:24
Hyper.js configuration for Windows OS
// Future versions of Hyper may add additional config options,
// which will not automatically be merged into this file.
// See https://hyper.is#cfg for all currently supported options.
module.exports = {
config: {
// choose either `'stable'` for receiving highly polished,
// or `'canary'` for less polished but more frequent updates
updateChannel: 'stable',
@adrianokerber
adrianokerber / .gitconfig
Last active July 14, 2022 03:57
Git - ˜/.gitconfig
[alias]
# Fetch all and prune branches
fp = fetch -p
fap = fetch --all -p
## ASSUME UNCHANGED: warning - to checkout to another commit remember to call *git update-index --no-assume-unchange <file>* to keep track of the file again
# List all files assumed as unchanged
ignored = !git ls-files -v | grep "^[[:lower:]]"
# Assume file unchanged
ignore = "!f() { git update-index --assume-unchanged \"$1\" \"$1\"; }; f"
public static java.util.List<FileItem> listDirectoryAppend(File dir, java.util.List<FileItem> lista) {
if (dir.isDirectory()) {
String[] filhos = dir.list();
for (int i = 0; i < filhos.length; i++) {
File nome = new File(dir, filhos[i]);
if (nome.isFile()) {
if (nome.getName().toUpperCase().endsWith(".GBK")) {
lista.add(new FileItem(nome));
}
} else if (nome.isDirectory()) {