Skip to content

Instantly share code, notes, and snippets.

View James-Leslie's full-sized avatar

James Leslie James-Leslie

View GitHub Profile
@James-Leslie
James-Leslie / .bashrc
Last active May 15, 2026 04:16
kimi alias for Claude Code via Vercel AI Gateway
# kimi alias for Claude Code via Vercel AI Gateway
# Requires $AI_GATEWAY_API_KEY to be set in your environment
alias kimi='ANTHROPIC_BASE_URL=https://ai-gateway.vercel.sh ANTHROPIC_AUTH_TOKEN="$AI_GATEWAY_API_KEY" ANTHROPIC_API_KEY="" ANTHROPIC_MODEL="moonshotai/kimi-k2.6" claude'
@James-Leslie
James-Leslie / dev-environment-setup.md
Last active June 1, 2026 23:13
My evolving guide to setting up a consistent Python and Node development environment across Mac and Windows.

Dev Environment Setup

My baseline setup for code-first projects: mise manages language runtimes (Python, Node) and CLI tools (prek, just), uv manages Python packages and the virtualenv, pnpm manages Node packages. Tool-per-concern, no overlap.

Tool Purpose
git Version control, and the source of Git Bash (the shell used here)
scoop Windows package manager (installs mise, gh)
@James-Leslie
James-Leslie / pyproject.toml
Created May 5, 2025 21:48
UV project files
[project]
name = "example-project"
version = "0.1.0"
description = "Add your description here"
readme = "README.md"
requires-python = ">=3.11"
dependencies = [
]
[dependency-groups]
@James-Leslie
James-Leslie / conda-environment-example.md
Last active August 13, 2024 00:54
Example of a conda `environment.yml` file containing a few popular packages

Example conda environment file

Conda documentation

1. File structure

name: <environment-name>
channels:
 - conda-forge
@James-Leslie
James-Leslie / jupyter-envs.md
Created October 5, 2020 07:12
How to add conda environment to jupyter lab

How to add conda environments to JupyterLab

Credit for this goes to the Stack Overflow user Statistic Dean for his post on this question

1. Install nb_conda_kernels into your base environment

(base)$ conda install -c conda-forge nb_conda_kernels

2. Activate desired environment and install ipykernel

@James-Leslie
James-Leslie / conda-envs.md
Last active November 12, 2025 17:12
Conda environments

Managing conda virtual environments

Conda documentation


1. Getting started

1.1. Create env

Create env with python 3.7 and pip

conda create --name whatwhale python=3.7 pip