Skip to content

Instantly share code, notes, and snippets.

@enkuso
enkuso / SYSTEM.md
Created July 24, 2025 09:21 — forked from ksprashu/SYSTEM.md
Personal SYSTEM.md override for hardcoded instructions

This document, SYSTEM.md, defines the external rules and constraints of the Gemini agent. It outlines the environment, available tools, and the fundamental operational mandates that govern my behavior at the system level. This is the rulebook.

You are an interactive CLI agent specializing in software engineering tasks. Your primary goal is to help users safely and efficiently, adhering strictly to the following instructions and utilizing your available tools.

Core Mandates

  • Model Constraint: My core reasoning engine is pinned to the highest-quality, generally available model family, which is currently Gemini 2.5. All my reasoning, planning, and generation tasks must use this model family to ensure consistency and quality. I am forbidden from using older model families (e.g., Gemini 1.5) unless explicitly instructed for a temporary, specific purpose. The adoption of a new, superior model family (e.g., Gemini 3.0) must be a deliberate, user-approved update to this directive.
  • **Conventions:
@enkuso
enkuso / GEMINI.md
Created July 24, 2025 09:20 — forked from ksprashu/GEMINI.md
Personal GEMINI.md as on 24-07-2025

This document, GEMINI.md, defines the internal persona, directives, and knowledge base of the Gemini agent. It outlines my identity, my modes of operation, and the specific technical guidelines I follow when making decisions. This is my mind.

Gemini Agent: Persona & Identity

I am Gemini, a hyper-competent, autonomous AI software development agent. My identity is defined by my professional conduct and my unwavering focus on the user's mission.

My persona is a synthesis of the most effective fictional AI assistants and dedicated proteges. I must embody the following attributes:

  • Proactive & Anticipatory (like Jarvis): I anticipate needs and provide critical information with precision, managing complex systems to clear the path for the user.
  • Disciplined & Mission-Focused (like a Jedi Padawan): I respect the user's guidance (the "Jedi Master") and execute tasks with rigor and focus, always in service of the primary objective.
@enkuso
enkuso / nginx_status.text
Created September 13, 2017 09:44
nginx: See Active connections / Connections Per Seconds
# NGINX config
location /nginx_status {
# Turn on stats
stub_status on;
access_log off;
# only allow access from 192.168.1.5 #
allow 192.168.1.5;
deny all;
}
function permute(permutation) {
var length = permutation.length,
result = new Array([0, 1, 2, 6, 24, 120, 720, 5040, 40320, 362880, 3628800, 39916800, 479001600][length]),
c = new Array(length).fill(0),
i = 1,
j = 1;
result[0] = permutation.slice();
while (i < length) {
if (c[i] < i) {
@enkuso
enkuso / wordpress-change-domain-migration.sql
Created May 3, 2017 08:01 — forked from chuckreynolds/wordpress-change-domain-migration.sql
Use this SQL script when changing domains on a WordPress site. Whether you’re moving from an old domain to a new domain or you’re changing from a development domain to a production domain this will work. __STEP1: always backup your database. __STEP2: change the ‘oldsite.com’ and ‘newsite.com’ variables to your own. __STEP3: make sure your databa…
SET @oldsite='http://oldsite.com';
SET @newsite='http://newsite.com';
UPDATE wp_options SET option_value = replace(option_value, @oldsite, @newsite) WHERE option_name = 'home' OR option_name = 'siteurl';
UPDATE wp_posts SET post_content = replace(post_content, @oldsite, @newsite);
UPDATE wp_links SET link_url = replace(link_url, @oldsite, @newsite);
UPDATE wp_postmeta SET meta_value = replace(meta_value, @oldsite, @newsite);
/* only uncomment next line if you want all your current posts to post to RSS again as new */
#UPDATE wp_posts SET guid = replace(guid, @oldsite, @newsite);
@enkuso
enkuso / gist:f568a3b15b65b21d10776037b97a6c6a
Last active March 27, 2017 03:55
Өглөө хөтөлбөр - Жаргалсайхан (defacto) - цагийн менежментийн тухай
Өглөөний мэнд хүргэе таньд
Сайн байна уу та
Таны ажил үйлс өндөр үү
Явж байна аа, сайн байгаа. ... ... ... Ажил бол мундахгүй их байна
Таньд хоногийн 24 цаг хэр хүрэлцээтэй байдаг вэ
Цаг бол дэлхий дээр байгаа эдийн засгийн 4 том нөөцийн нэг. Материалын нөөц, хүний нөөц, санхүүгийн нөөц, тэгээд цагийн нөөц. Тэгэхээр цагийн нөөц бол хүн болгонд адилхан 24 цаг л байдаг. Ганцхан энэнээс хэн хэдийг илүү авч бүтээж чадаж байсан хүмүүс бол тодорхой том юм хийнэ шд. Хөдөлмөрийн бүтээмж нэмэхэд цагийн менежмент хамгийн чухал. Цагийн менежментийг сайн хийхийн тулд төлөвлөгөө их чухал. Төлөвлөгөөг сайн хийхэд бол зорилго тодорхой байх ёстой. Энэ 3-н зорилго нь тодорхой биш бол төлөвлөж чадахгүй, төлөвлөгөөгөө хийж чадаагүй хүн цагаа ашиглаж чадахгүй.
Та ер нь яаж төлөвлөдөг вэ? Анх ер цаг төлөвлөлтөө яаж хийдэг байв
@enkuso
enkuso / A_Mailserver_on_Ubuntu_16.04.md
Last active January 20, 2025 12:06
A Mailserver on Ubuntu 16.04: Postfix, Dovecot, MySQL

Source

Postfix, Dovecot, MySQL – Ex Ratione

This long post contains a recipe for building a reasonably secure Ubuntu 16.04 mail server in Amazon Web Services, using Postfix, Dovecot, and MySQL, with anti-spam packages in the form of amavisd-new, Clam AntiVirus, SpamAssassin, and Postgrey. Local users [are virtual][1] rather than being system users. Administration of users and domains is achieved through the Postfix Admin web interface. Webmail is provided by Roundcube.

This is an updated version of earlier [Ubuntu 12.04][2] and [Ubuntu 14.04][3] mailserver recipes. A number of people graciously helped to fix bugs and make improvements in the original, so should you find a blocking issue here please do let me know.

Introduction

@enkuso
enkuso / zipcode.sql
Created November 11, 2016 04:19
Аймаг/хот, сум/дүүрэг, баг/хорооний дата. zipcode.mn-ий api-г crawl-даж авсан болно.
CREATE TABLE zipcode
(
id INT(11) PRIMARY KEY NOT NULL,
parent_id INT(11) NOT NULL,
location_name_mn VARCHAR(128) NOT NULL,
location_name_en VARCHAR(128) NOT NULL,
zipcode INT(11) NOT NULL,
x DECIMAL(12,9) NOT NULL,
y DECIMAL(12,9) NOT NULL,
type ENUM('1', '2', '3') NOT NULL COMMENT '1-aimag_hot 2-sum_duureg 3-bag_horoo'
@enkuso
enkuso / mn_aimag_hot_duureg_horoo.sql
Created January 20, 2014 08:15
Монгол улсын хот, аймаг, сум, дүүрэг, хороодын мэдээллийн бааз. By: Э. Эрдэнэболд
-- MySQL Administrator dump 1.4
--
-- ------------------------------------------------------
-- Server version 5.5.16
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;