Skip to content

Instantly share code, notes, and snippets.

View juliosouzam's full-sized avatar
🎯
Focusing

Júlio César juliosouzam

🎯
Focusing
  • Solar Coca Cola
  • Fortaleza-CE
View GitHub Profile
@juliosouzam
juliosouzam / biome.json
Created January 26, 2024 03:20
biome.json
{
"$schema": "https://biomejs.dev/schemas/1.5.2/schema.json",
"organizeImports": {
"enabled": true
},
"formatter": {
"enabled": true,
"indentWidth": 2,
"indentStyle": "space",
"lineWidth": 80,
@juliosouzam
juliosouzam / fix-sysctl.txt
Created June 22, 2021 18:52 — forked from iamcryptoki/fix-sysctl.txt
Fix sysctl: cannot stat /proc/sys/net/bridge/bridge-nf-call-iptables.
$ modprobe bridge
$ echo "net.bridge.bridge-nf-call-iptables = 1" >> /etc/sysctl.conf
$ sysctl -p /etc/sysctl.conf
sysctl: cannot stat /proc/sys/net/bridge/bridge-nf-call-iptables: No such file or directory sysctl: cannot stat /proc/sys/net/bridge/bridge-nf-call-ip6tables: No such file or directory
# SOLUTION
$ modprobe br_netfilter
$ sysctl -p /etc/sysctl.conf
@juliosouzam
juliosouzam / multi-select.js
Created May 4, 2021 06:26 — forked from csandman/README.md
A Chakra UI wrapper for react-select, made to be used as a multi-select which Chakra does not currently have
/* eslint-disable no-underscore-dangle */
// Demo: https://codesandbox.io/s/chakra-ui-react-select-648uv?file=/multi-select.js
import React from 'react';
import Select, { components as selectComponents } from 'react-select';
import {
Flex,
Tag,
TagCloseButton,
TagLabel,
import { createContext, ReactNode, useContext, useEffect } from 'react';
import { useDisclosure, UseDisclosureReturn } from '@chakra-ui/react';
import { useRouter } from 'next/router';
interface SidebarDrawerProviderProps {
children: ReactNode;
}
type SidebarDrawerContextData = UseDisclosureReturn;
import { Flex, Icon, IconButton, useBreakpointValue } from '@chakra-ui/react';
import { RiMenuLine } from 'react-icons/ri';
import { useSidebarDrawer } from '../../contexts/SidebarDrawerContext';
import { Logo } from './Logo';
import { NotificationsNav } from './NotificationsNav';
import { Profile } from './Profile';
import { SearchBox } from './SearchBox';
export function Header() {
import {
Box,
Drawer,
DrawerBody,
DrawerCloseButton,
DrawerContent,
DrawerOverlay,
DrawerHeader,
useBreakpointValue,
} from '@chakra-ui/react';

Problem

In Arch Linux mkinitcpio -p linux

shows

Possibly missing firmware for module: aic94xx
 Possibly missing firmware for module: wd719x
/* eslint-disable import/no-dynamic-require */
/* eslint-disable global-require */
import Sequelize from 'sequelize';
import fs from 'fs';
import path from 'path';
import databaseConfig from '../config/database';
class Database {
constructor() {
{
"states": [
{
"uf": "AC",
"name": "Acre"
},
{
"uf": "AL",
"name": "Alagoas"
},
@juliosouzam
juliosouzam / discord_oauth2.md
Created January 29, 2021 22:14 — forked from Vap0r1ze/discord_oauth2.md
Discord OAuth2 Flow

Discord OAuth2

Step 1

You: Redirect User to https://discordapp.com/api/oauth2/authorize

Query Params
name value
client_id Your application's Client ID
scope A list of scopes, delimited by spaces
redirect_uri The uri to send the user after authorization