Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 27 additions & 0 deletions .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,2 +1,29 @@
# [Choice] Python version: 3.9, 3.10, 3.11
FROM python:latest

# Install system dependencies and development tools
RUN apt-get update && apt-get install -y --no-install-recommends \
htop \
tree \
ripgrep \
fzf \
fd-find \
bat \
eza \
&& rm -rf /var/lib/apt/lists/*

# Install Language Server Protocol (LSP) support
RUN apt-get update && apt-get install -y --no-install-recommends \
python3-pip \
nodejs \
npm \
&& rm -rf /var/lib/apt/lists/*

# Install Python language server
RUN pip install --no-cache-dir python-lsp-server

# Install Node.js language server
npm install -g typescript npm

# Clean up
RUN apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
17 changes: 14 additions & 3 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,15 +30,16 @@
"customizations": {
"vscode": {
"extensions": [

// General extensions
"GitHub.copilot",
"GitHub.copilot-labs",
"GitHub.copilot-chat",
"eamodio.gitlens",
"EditorConfig.EditorConfig",
"streetsidesoftware.code-spell-checker",
"esbenp.prettier-vscode"
"esbenp.prettier-vscode",
"ms-python.python",
"ms-pylance.vscode-pylance"
],

"settings": {
Expand Down Expand Up @@ -70,6 +71,16 @@
"[typescript]": {
"editor.defaultFormatter": "esbenp.prettier-vscode",
"editor.formatOnSave": true
},
// Neovim configuration
"neovim.enableNeovim": true,
"neovim.enableNvimConfigFile": true,
"neovim.experimental.preferLuaConfig": true,
"editor.defaultFormatter": "shd101wyy.vscode-stylelint",
"editor.formatOnSave": true,
"editor.codeActionsOnSave": {
"source.fixAll": true,
"source.organizeImports": true
}
}
}
Expand All @@ -78,4 +89,4 @@
"onCreateCommand": "/usr/bin/zsh ./.devcontainer/on-create.sh > ~/on-create.log",
"postCreateCommand": "/usr/bin/zsh ./.devcontainer/post-create.sh > ~/post-create.log",
"remoteUser": "vscode"
}
}
24 changes: 24 additions & 0 deletions .devcontainer/on-create.sh
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
#!/bin/bash
set -e

## Install additional apt packages
sudo apt-get update && \
sudo apt upgrade -y && \
Expand All @@ -8,3 +11,24 @@ sudo apt-get update && \
## Configure git
git config --global pull.rebase false

## Install Neovim configuration
mkdir -p ~/.config/nvim
cat > ~/.config/nvim/init.vim << 'VIMRC'
" Neovim basic configuration
syntax enable
filetype plugin indent on
set number
set relativenumber
set expandtab
set shiftwidth=2
set tabstop=2
set smartindent
set autoindent
set smartcase
set ignorecase
set hlsearch
set incsearch
set wrap
VIMRC

echo "Neovim configuration installed"
15 changes: 15 additions & 0 deletions .devcontainer/post-create.sh
100644 → 100755
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
#!/bin/bash
set -e

# Setup Python environment
python3 -m pip install --upgrade pip
python3 -m pip install black pylint pytest

# Setup Node.js environment
npm install -g eslint

# Create project structure if needed
mkdir -p src tests docs

echo "Development environment setup complete!"
echo "Neovim is configured with Python and JavaScript support"