Skip to content

Instantly share code, notes, and snippets.

View jniltinho's full-sized avatar
🏠
Working from home

Nilton Oliveira jniltinho

🏠
Working from home
View GitHub Profile
@jniltinho
jniltinho / .gitignore
Last active September 23, 2026 16:50
Linux users with Ansible: SSH keys, sudo and history in Git (linuxpro.com.br)
# secrets and private keys never go into the repository
.vault-pass*
id_*
*.pem
*.key
*.retry
@jniltinho
jniltinho / .dockerignore
Created September 23, 2026 01:40
Vue.js + Go com Echo v5: app de tarefas com login, embed e Docker (série LinuxPro)
.git
bin
web/node_modules
web/dist
@jniltinho
jniltinho / README.md
Last active September 8, 2026 17:37
ai-shim: ponte OpenAI-compatible (/v1/chat/completions) para CLIs de IA — codex, claude, cursor, opencode e grok. Go, stdlib apenas.

ai-shim — an OpenAI-compatible bridge to AI CLIs

Serves POST /v1/chat/completions on 127.0.0.1 and forwards each request to an agent CLI installed on the machine.

The point: half the AI tooling out there speaks one dialect — OpenAI chat completions — and exposes a configurable base_url. Meanwhile, the subscriptions you already pay for (ChatGPT Plus/Pro, Claude, Cursor) live inside a terminal with no HTTP endpoint at all. This bridges the two, so any OpenAI-speaking application can drive a CLI-bound subscription without an API

@jniltinho
jniltinho / 00 - Cursor AI Prompting Rules.md
Created March 23, 2025 19:30 — forked from aashari/00 - Cursor AI Prompting Rules.md
Cursor AI Prompting Rules - This gist provides structured prompting rules for optimizing Cursor AI interactions. It includes three key files to streamline AI behavior for different tasks.

Cursor AI Prompting Framework

This repository provides a structured set of prompting rules to optimize interactions with Cursor AI. It includes three key files to guide the AI’s behavior across various coding tasks.

Files and Their Roles

core.md

  • Purpose: Establishes foundational rules for consistent AI behavior across all tasks.
  • Usage: Place this file in your project’s .cursor/rules/ folder to apply it persistently:
  • Save core.md under .cursor/rules/ in the workspace root.
@jniltinho
jniltinho / cursor-bash-linux.sh
Last active March 9, 2025 22:14
Cursor IDE AppImage Launcher (Linux)
#!/usr/bin/env bash
#
# Cursor IDE AppImage Launcher v0.3.0
#
# Launches Cursor IDE with proper path handling and logging.
#
# 2025-03-01: Support for wait flag added.
# 2025-02-21: Created by monnef and Claude 3.6 Sonnet via Perplexity + AIlin and Cursor
#
# License: GPLv3
@jniltinho
jniltinho / mariadb-galera-cluster.sh
Last active September 6, 2026 15:10
Install MariaDB Galera Cluster
#!/bin/bash
## https://www.howtoforge.com/how-to-setup-mariadb-galera-cluster-on-ubuntu-20-04/
## https://www.linkedin.com/pulse/setting-up-mariadb-galera-multi-node-cluster-ubuntu-2204-sahu-azrjc
## https://computingforgeeks.com/how-to-setup-mariadb-galera-cluster-on-ubuntu-with-haproxy/
## https://mariadb.com/kb/en/mariadb-package-repository-setup-and-usage/
## https://mariadb.com/kb/en/mariabackup-sst-method/
## https://mariadb.com/kb/en/mariadb-package-repository-setup-and-usage/
## https://mariadb.org/download/?t=repo-config&d=22.04+%22jammy%22&v=10.6&r_m=rackspace
@jniltinho
jniltinho / install-jdk7_80.sh
Last active January 30, 2025 15:01
Install JDK 7_80 Linux
#!/bin/bash
# See https://gist.github.com/bmaupin/87631863d55e2accc05ca7759247f887
## https://knowledge.broadcom.com/external/article/41808/resolving-problems-installing-the-java.html
## https://www.oracle.com/java/technologies/javase-jce7-downloads.html
## https://repo.huaweicloud.com/java/jdk/7u80-b15/
wget --no-cookies --no-check-certificate \
--header "Cookie: gpw_e24=http%3A%2F%2Fwww.oracle.com%2F; oraclelicense=accept-securebackup-cookie" \
-O jce_policy-8.zip http://download.oracle.com/otn-pub/java/jce/8/jce_policy-8.zip
@jniltinho
jniltinho / install-rspamd-stable.sh
Last active December 17, 2024 19:41 — forked from Razuuu/install-rspamd-stable.sh
Install rspamd stable - Ubuntu/Debian
#!/bin/bash
# See https://rspamd.com/downloads.html
apt update
apt install -y sudo lsb-release wget gpg
CODENAME=$(lsb_release -c -s)
if [ $CODENAME = "trixie" ]; then
CODENAME="bookworm"
fi
@jniltinho
jniltinho / install-imapsync
Last active September 6, 2026 15:06
Install IMAPSYNC Ubuntu
#!/bin/bash
#
## https://github.com/imapsync/imapsync/tree/master/INSTALL.d
## https://github.com/imapsync/imapsync/blob/master/INSTALL.d/Dockerfile
## https://raw.githubusercontent.com/imapsync/imapsync/master/imapsync
## https://www.managedserver.eu/how-to-migrate-emails-from-one-server-to-another-using-imapsync/
apt update
apt install -y libauthen-ntlm-perl libcgi-pm-perl libcrypt-openssl-rsa-perl libdata-uniqid-perl libparse-recdescent-perl
apt install -y libencode-imaputf7-perl libfile-copy-recursive-perl libfile-tail-perl libio-compress-perl libio-socket-ssl-perl