Skip to content

Instantly share code, notes, and snippets.

View wilcorrea's full-sized avatar
🚀
// TODO: be life good

William Correa wilcorrea

🚀
// TODO: be life good
View GitHub Profile
@wilcorrea
wilcorrea / .env
Created May 7, 2026 14:45
Onyx (AI Knowledge Base) — VPS Deploy for ai.devi.tools
# =============================================================================
# Onyx VPS Environment Configuration
# =============================================================================
# IMPORTANT: Change the passwords below before deploying!
# --- Onyx Image ---
IMAGE_TAG=latest
# --- Domain ---
DOMAIN=ai.devi.tools
<?php
declare(strict_types=1);
namespace App\Domain\Entity\Command;
use App\Domain\Enum\Type;
use Constructo\Support\Entity;
class EntityCommand extends Entity
# INHERIT: mkdocs.yml
site_name: "Docs"
site_description: "Docs description"
site_url: "https://github.com/<org>/<app>"
theme:
name: material
language: en
features:
#!/bin/bash
# Disable git pager
export GIT_PAGER=cat
untracked=$(git clean -d --dry-run)
changes=$(git status --short)
if [ -z "$untracked" ] && [ -z "$changes" ]; then
echo "Nothing to purge, working tree clean"
@wilcorrea
wilcorrea / php.sh
Created July 30, 2025 13:05
dockerized php
#!/bin/bash
ACTION="$1"
case ${ACTION} in
"stop")
docker stop php-cli
;;
"start")
docker run --rm --name php-cli -i -t -d \
@wilcorrea
wilcorrea / .zshrc
Last active January 29, 2025 21:51
How to configure oh-my-szh + p10k
# ...
plugins=(
git
git-extras
screen
sudo
history
docker
docker-compose
/* eslint-disable @typescript-eslint/no-explicit-any */
import { reactive } from 'vue'
type StoreMutation<StoreState> = (state: StoreState, ...args: any[]) => void
type StoreMutations<StoreState> = Record<string, StoreMutation<StoreState>>
type Store<StoreState> = {
state: StoreState
commit (mutation: string, ...args: any[]): void
gu () {
if [ -z "$1" ]; then
echo "Help"
echo " 0: 'a@mail.com'"
echo " 1: 'b@mail.com'"
else
case $1 in
0) account="a@mail.com";;
1) account="b@mail.com";;
@wilcorrea
wilcorrea / reset.bat
Created May 11, 2023 11:05
Reset Git setup on Windows
@echo off
git config --system --unset credential.helper
git config --global --unset credential.helper
git config --global credential.modalprompt false
git config --global init.defaultbranch main
git config --global pull.rebase true
set /p "email=Enter Email: "
git config --global user.email "%email%"
<?php
if (!function_exists('getClientAddress')) {
/**
* @return string|null
*/
function getClientAddress(): ?string
{
return $_SERVER['HTTP_CLIENT_IP']