Skip to content

Instantly share code, notes, and snippets.

View terion-labs's full-sized avatar

Terion terion-labs

View GitHub Profile
@terion-labs
terion-labs / README.md
Last active August 8, 2026 09:26 — forked from ocombe/README.md
ChatGPT Conversation Exporter — export all your conversations as JSON + Markdown + ZIP. No dependencies beyond bash, curl, python3.

Forked from https://gist.github.com/ocombe/1d7604bd29a91ceb716304ef8b5aa4b5 and added script for exporting currently opened conversation only

ChatGPT Conversation Exporter

Export all your ChatGPT conversations as JSON + Markdown + HTML + ZIP. Works with ChatGPT Business/Team/Enterprise accounts (including SSO/Okta).

What's exported

@terion-labs
terion-labs / readme.md
Last active July 31, 2025 13:36
get typed default values from zod schema

for zod3.ts works and types correctly

zod4 version yet requires some adjustments and tests

@terion-labs
terion-labs / dnsmasq OS X.md
Last active June 22, 2022 11:58 — forked from ogrrd/dnsmasq OS X.md
Setup dnsmasq on OS X

Never touch your local /etc/hosts file in OS X again

To setup your computer to work with *.local domains, e.g. project.local, awesome.local and so on, without having to add to your hosts file each time.

Requirements

Install

@terion-labs
terion-labs / res.txt
Created September 13, 2021 14:47
second max compare
Length of random ints array: 1000000
Run looper
res: 99999883
Time elapsed: 7
Run reducer
res: 99999883
Time elapsed: 26
Diff: 19
@terion-labs
terion-labs / fix_vagrant_vmware_port_collision.sh
Created June 27, 2020 10:59
fix vagrant vmware port collision
sudo rm -f /opt/vagrant-vmware-desktop/settings/nat.json
sudo killall vagrant-vmware-utility
@terion-labs
terion-labs / Spoiler.js
Last active May 26, 2016 12:37
slideUp / slideDown on transition
export default class Spoiler {
constructor(container) {
this.container = container;
this.opener = this.container.querySelector('.opener');
this.content = this.container.querySelector('.content');
this.isAnimating = false;
this.opened = false;
this.container.addEventListener(transitionend, ()=>{
this.isAnimating = false;
@terion-labs
terion-labs / gulp_js.js
Created May 7, 2016 12:36
gulp static sites build approach
const gulp = require('gulp');
const watch = require('gulp-watch');
const browserify = require('browserify');
const babelify = require('babelify');
const transform = require('vinyl-transform');
const minify = require('gulp-minify');
const ifElse = require('gulp-if-else');
const argv = require('yargs').argv;
@terion-labs
terion-labs / add_docker_inspect_to_www-data.sh
Last active January 13, 2016 11:02
nginx config for resolving docker containers
echo "www-data ALL=(ALL:ALL) NOPASSWD:/usr/bin/docker inspect *" >> /etc/sudoers
@terion-labs
terion-labs / JsonUploader.php
Created January 9, 2016 16:00
Get uploads from RAW multipart post-request that is sent by some frontend async uploaders
<?php
namespace App\Support;
/**
* Get files from raw multipart input generated by frontend ajax uploaders
*
* Class JsonUploader
* @package App\Support
@terion-labs
terion-labs / iftrue.js
Last active December 30, 2015 18:51
Ember Handlebars "ternary" helper
// app/helpers/iftrue.js
import Ember from 'ember';
export function iftrue(params) {
if (params[0]) {
return params.length === 2 ? params[0] : params[1];
}
if (params.length === 2) {
return params[1];
} else if (params.length === 3) {