Skip to content

Instantly share code, notes, and snippets.

View gmdias727's full-sized avatar

Gabriel Mazieri gmdias727

View GitHub Profile
@gmdias727
gmdias727 / seed_drizzle_zod_faker.ts
Created November 7, 2024 03:40 — forked from ironbyte/seed_drizzle_zod_faker.ts
TS Seed Script: Drizzle ORM + Zod + Faker (Minimal)
// tsx seed.ts
import { faker } from '@faker-js/faker';
import { pgTable, text, varchar, timestamp } from 'drizzle-orm/pg-core';
import { drizzle, PostgresJsDatabase } from 'drizzle-orm/postgres-js';
import { createInsertSchema } from 'drizzle-zod';
import { customAlphabet } from 'nanoid';
import postgres from 'postgres';
import { z } from 'zod';
// Zed settings
//
// For information on how to configure Zed, see the Zed
// documentation: https://zed.dev/docs/configuring-zed
//
// To see all of Zed's default settings without changing your
// custom settings, run `zed: open default settings` from the
// command palette (cmd-shift-p / ctrl-shift-p)
{
"outline_panel": {
@gmdias727
gmdias727 / index.js
Created August 26, 2024 15:00
GET ALL CARDS FROM TRELLO BOARD
import fetch from 'node-fetch';
import fs from "fs";
import { formatDate } from "date-fns"
// provide the following
const key = ""
const token = ""
const boardId = ""
fetch(`https://api.trello.com/1/boards/${boardId}/cards?key=${key}&token=${token}`, {
################################################################################################################################################################################
projeto lol voice chat
utilizar para pensar: https://gist.github.com/EduardoRFS/17f3409a22c1ca5eedc8a9673833424a
1. descobrir como encontrar jogadores com partidas em andamento utilizando a api da riot games
2. descobrir como diferenciar jogadores do time azul e time vermelho utilizando a api da riot games
3. integrar essa descoberta em um bot de discord
4. bot gera 2 canais de voz no discord [red, blue] com um identificador de partida.
5. jogadores interessados em canal de voz precisam estar no servidor do discord

curl

curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.7/install.sh | bash

wget

wget -qO- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.7/install.sh | bash

Profile of a great golang developer:

  • Golang fluency and 1+ language (Python, TS/JS, C/C++, Java, Node.js)
  • Kubernetes
  • Microservices
  • Protobuf
  • Strong networking knowledge DNS.
  • Know everything from concept to deployment
  • Write technical documentation

Tests:

#!/bin/bash
# basic system update and cleanup
sudo apt update -y && sudo apt upgrade -y && sudo apt autoremove -y
sudo apt install git curl neovim -y
# install nvm steps
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.5/install.sh | bash
@gmdias727
gmdias727 / gist:3c63262351eb6fd5ce91629c5dde6d68
Last active August 25, 2023 13:05
How to install mysql on ubuntu 22+
sudo apt update -y
sudo apt install mysql-server
systemctl is-active mysql
sudo mysql_secure_installation
mysql -u root -p
clear lock
clear mod3
clear mod4
keycode 66 = Hyper_L NoSymbol Hyper_L
add mod3 = Hyper_L
add mod4 = Super_R

Por favor responda estas seguintes perguntas: (dê preferência por respondar logo abaixo deste gist e tente ser breve em suas respostas)

  • Primeiro nome:

  • qual o seu discord? (para entrarmos em contato quando necessário)

  • qual seu email? (para te adicionarmos ao pipefy que será o nosso backlog de tarefas)

  • faz faculdade? (para sabermos lidar melhor com seus horários)