Skip to content

Instantly share code, notes, and snippets.

View ThiagoGodinhoPaschoalin's full-sized avatar

Thiago Godinho Paschoalin ThiagoGodinhoPaschoalin

View GitHub Profile
@ThiagoGodinhoPaschoalin
ThiagoGodinhoPaschoalin / AWS_STARTED_WITH_LOCALSTACK.md
Last active November 25, 2024 12:57
Get started on AWS for free with this great tool called LOCALSTACK; Inicie gratuitamente na AWS com essa ótima ferramenta, chamada LOCALSTACK;
@ThiagoGodinhoPaschoalin
ThiagoGodinhoPaschoalin / NormalizeAnyString.md
Last active February 6, 2025 12:12
Normalize any string for better compare

Normalize any string

A simple algorithm to normalize any text, removing any white space, special characters and accents.

.NET C#

dotnet new console -f net8.0 -n HowToNormalizeString
cd .\HowToNormalizeString\
cp dotnet.cs Program.cs
@ThiagoGodinhoPaschoalin
ThiagoGodinhoPaschoalin / Invoke-URLInDefaultBrowser.ps1
Last active February 28, 2023 19:18 — forked from jkdba/Invoke-URLInDefaultBrowser.ps1
PowerShell cmdlet to open a URL in the user's default browser.
function Invoke-URLInDefaultBrowser
{
<#
.SYNOPSIS
Cmdlet to open a URL in the User's default browser.
.DESCRIPTION
Cmdlet to open a URL in the User's default browser.
.PARAMETER URL
Specify the URL to be Opened.
.EXAMPLE
#!/usr/bin/env python
# Acredito que o crédito vai para o usuário deste tópico:
# -> https://stackoverflow.com/questions/51645324/how-to-setup-a-aiohttp-https-server-and-client
"""
stuff for network security
"""
import socket
import datetime
@ThiagoGodinhoPaschoalin
ThiagoGodinhoPaschoalin / main.yml
Created March 15, 2021 02:37
igti_ansible_roles_docker_tasks_main.yml
---
- name: 'Adiciona repositório do Docker'
get_url:
url: https://download.docker.com/linux/centos/docker-ce.repo
dest: /etc/yum.repos.d/docker-ce.repo
- name: 'Instala os pacotes do Docker e o pacote epel-release'
yum:
name: "{{ packages }}"
state: latest
@ThiagoGodinhoPaschoalin
ThiagoGodinhoPaschoalin / recursive_find_childs.sql
Last active February 18, 2019 00:26
Consulta recursiva para encontrar toda hierarquia...
--Montando Tabelas de exemplo:
DECLARE @TABLE_TAG TABLE (Id uniqueidentifier, Name varchar(50));
DECLARE @TABLE_UNION TABLE (ParentId uniqueidentifier, ChildId uniqueidentifier);
INSERT INTO @TABLE_TAG (Id, Name) VALUES
(NEWID(), 'Pai'), (NEWID(), 'FilhoA') , (NEWID(), 'FilhoB'), (NEWID(), 'NetoA'), (NEWID(), 'NetoB'), (NEWID(), 'NetoC'), (NEWID(), 'BisnetoA');
INSERT INTO @TABLE_UNION (ParentId, ChildId) VALUES
( (SELECT Id FROM @TABLE_TAG WHERE Name = 'Pai'), (SELECT Id FROM @TABLE_TAG WHERE Name = 'FilhoA') ),
( (SELECT Id FROM @TABLE_TAG WHERE Name = 'FilhoA'), (SELECT Id FROM @TABLE_TAG WHERE Name = 'NetoA') ),
( (SELECT Id FROM @TABLE_TAG WHERE Name = 'FilhoA'), (SELECT Id FROM @TABLE_TAG WHERE Name = 'NetoB') ),
@ThiagoGodinhoPaschoalin
ThiagoGodinhoPaschoalin / QnAMaker_v4.0_example_api.cs
Last active May 25, 2018 12:03
A example of call QnA v4 in C#
using System;
using System.Collections.Generic;
using System.Net.Http;
using System.Text;
using System.Threading.Tasks;
namespace Microsoft.BotBuilder
{
public static class QnAMaker
{