
Research
Malicious npm Packages Impersonate Flashbots SDKs, Targeting Ethereum Wallet Credentials
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
title: zer0-mistakes sub-title: Jekyll Theme description: Docker-optimized Jekyll theme with AI-powered installation automation and comprehensive error handling. version: 2.0.0 tags:
This is a Docker-optimized Jekyll theme with AI-powered installation automation, and comprehensive error handling. It embodies IT-Journey principles of Design for Failure (DFF), Don't Repeat Yourself (DRY), Keep It Simple (KIS), and AI-Powered Development (AIPD).
curl -fsSL https://raw.githubusercontent.com/bamr87/zer0-mistakes/main/install.sh | bash
gh repo clone bamr87/zer0-mistakes
cd zer0-mistakes
docker-compose up
# Installs and configures everything automatically
curl -fsSL https://raw.githubusercontent.com/bamr87/zer0-mistakes/main/install.sh | bash
# Results in working Docker environment:
docker-compose up # Just works!
Metric | Before | After | Improvement |
---|---|---|---|
Build Success Rate | ~60% | ~95% | +58% |
Setup Time | 15-30 min | 2-5 min | -80% |
Docker Compatibility | Limited | Universal | +100% |
Error Recovery | Manual | Automatic | +100% |
# Confirm your system information
system_profiler SPHardwareDataType | awk '/Model Name:|Model Identifier:|Model Number:|Chip:|System Firmware Version:/ {print $0}'
system_profiler SPSoftwareDataType | awk '/System Version:|Kernel Version:/ {print $0}'
Before we begin, make sure you have the following software installed on your machine:
For step-by-step instructions on how to install these tools, visit the "Quickstart" section of the site here: Quickstart
To use these tools effectively, you need:
More importantly, you need to:
Make sure you have the following installed on your machine:
# Check if git is installed
if ! git --version > /dev/null 2>&1; then
echo "git is not installed. Installing..."
brew install git
else
echo "git is already installed."
fi
# Check if gh is installed
if ! gh --version > /dev/null 2>&1; then
echo "gh is not installed. Installing..."
brew install gh
else
echo "gh is already installed."
fi
# Check if gh is authenticated
if ! gh auth status > /dev/null 2>&1; then
echo "gh is not authenticated. Please authenticate..."
gh auth login
else
echo "gh is already authenticated."
fi
# Check if Docker is installed
if ! docker --version > /dev/null 2>&1; then
echo "Docker is not installed. Installing..."
brew install --cask docker
else
echo "Docker is already installed."
fi
# Check if Visual Studio Code is installed
if ! code --version > /dev/null 2>&1; then
echo "Visual Studio Code is not installed. Installing..."
brew install --cask visual-studio-code
else
echo "Visual Studio Code is already installed."
fi
The zer0-mistakes Jekyll theme can be installed in any repository using the included installation script. This script copies all essential theme files and creates the proper directory structure.
# Clone this repository
git clone https://github.com/bamr87/zer0-mistakes.git
cd zer0-mistakes
# Install the theme in a new directory
./install.sh my-new-site
# Or install in current directory
./install.sh .
The installation script copies the following essential files:
Configuration Files:
_config.yml
- Main Jekyll configuration_config_dev.yml
- Development configurationfrontmatter.json
- VS Code frontmatter configurationBuild & Dependency Files:
Gemfile
- Ruby dependenciesRakefile
- Build taskspackage.json
- Node.js dependenciesDocker Files:
docker-compose.yml
- Multi-container setupDockerfile
- Container configurationTheme Directories:
_data/
- Site data files and navigation_sass/
- Sass stylesheets and custom styles_includes/
- Reusable template components_layouts/
- Page layout templatesassets/
- Static assets (CSS, JS, images)Static Files:
404.html
- Custom error pagefavicon.ico
- Site iconindex.md
- Homepage (only if not exists)Additional Files:
.gitignore
- Git ignore rules (only if not exists)INSTALLATION.md
- Setup instructions# Show help and usage information
./install.sh --help
# Install in current directory
./install.sh
# Install in a specific directory
./install.sh /path/to/my-site
# Install in a relative directory
./install.sh ../my-new-site
Once installed, navigate to your new site directory and start developing:
cd my-new-site
# Using Docker (recommended)
docker-compose up
# Or using local Ruby environment
bundle install
bundle exec jekyll serve --config _config_dev.yml
# Your site will be available at http://localhost:4000
After installation:
_config.yml
with your site details_sass/custom.scss
for custom stylingpages/
directory_data/navigation/
files for site navigationFor detailed setup instructions, see the INSTALLATION.md
file created during installation.
{% if site.level == 'her0' %} {% include zer0-env-var.html %} {% endif %}
# Or use the following to set the environment variables
export GITHOME=~/github
export GHUSER=$(gh api user --jq '.login')
export GIT_REPO=zer0-mistakes
export ZREPO=$GITHOME/$GIT_REPO
#open Code to edit your shell profile and copy the environment variables
code ~/.zprofile
# Confirm the environment variables by echoing them
echo $GITHOME # /Users/bamr87/github
echo $GHUSER # bamr87
echo $GIT_REPO # zer0-mistakes
echo $ZREPO # /Users/bamr87/github/zer0-mistakes
# Set your Git email and name to tag your commits
git config --global user.email "$GHUSER@users.noreply.github.com"
git config --global user.name "$GHUSER"
See here for details.
# If you didnt already set it in the previous step
# FIXME: quotes in comments dont work
echo "What is your Github ID?"
read GIT_ID
# Set your email using ID
git config --global user.email "$GIT_ID+$GHUSER@users.noreply.github.com"
# confirm your email
git config -l
# Create your github home directory and repo
mkdir -p $ZREPO
# Initialize your github repository
gh repo create $GIT_REPO --gitignore Jekyll -l mit --public
# If new repo, initialize it
cd $ZREPO
git init
git remote add origin https://github.com/${GHUSER}/${GIT_REPO}.git
git pull origin main
curl https://raw.githubusercontent.com/bamr87/it-journey/master/zer0.md > README.md
git add README.md
git commit -m "Init $GIT_REPO"
git branch -M main
git push -u origin main
Go to your new github repository.
# Open your new github repository in the browser
open https://github.com/${GHUSER}/${GIT_REPO}
# Create a new Gemfile
cd $ZREPO
touch Gemfile
# Write the non-commented lines to the Gemfile
echo 'source "https://rubygems.org"' >> Gemfile
echo "gem 'github-pages' , '231'" >> Gemfile
echo "gem 'jekyll' , '3.9.5'" >> Gemfile
echo "gem 'jekyll-theme-zer0' , '0.1.2'" >> Gemfile
echo "group :jekyll_plugins do" >> Gemfile
echo " gem 'jekyll-feed', \"~> 0.17\"" >> Gemfile
echo " gem 'jekyll-sitemap' , \"~> 1.4.0\"" >> Gemfile
echo " gem 'jekyll-seo-tag', \"~> 2.8.0\"" >> Gemfile
echo " gem 'jekyll-paginate', '~> 1.1'" >> Gemfile
echo "end" >> Gemfile
code _config.yml
theme: jekyll-theme-zer0
title: zer0-mistakes
email: bamr87@zer0-mistakes.com
description: >- # this means to ignore newlines until "baseurl:"
Write an awesome description for your new site here. You can edit this
line in _config.yml. It will appear in your document head meta (for
Google search results) and in your feed.xml site description.
baseurl: null # the subpath of your site, e.g. /blog
url: null # the base hostname & protocol for your site, e.g. http://example.com
twitter_username: bamr87
github_username: bamr87
# Create a new Dockerfile
cd $ZREPO
touch Dockerfile
# Write the content to the Dockerfile
echo "# Use an official Ruby runtime as a parent image" >> Dockerfile
echo "FROM ruby:2.7.4" >> Dockerfile
echo "# escape=\\" >> Dockerfile
echo "ENV GITHUB_GEM_VERSION 231" >> Dockerfile
echo "ENV JSON_GEM_VERSION 1.8.6" >> Dockerfile
echo "ENV GIT_REPO ${GIT_REPO}" >> Dockerfile
echo "WORKDIR /app" >> Dockerfile
echo "ADD . /app" >> Dockerfile
echo "RUN gem update --system 3.3.22" >> Dockerfile
echo "RUN bundle update" >> Dockerfile
echo "RUN bundle install" >> Dockerfile
echo "RUN bundle clean --force" >> Dockerfile
echo "EXPOSE 4000" >> Dockerfile
echo 'CMD ["bundle", "exec", "jekyll", "serve", "--host", "0.0.0.0"]' >> Dockerfile
# build the docker image based on the Dockerfile
docker build -t ${GIT_REPO} .
# Run the container in detached mode
docker run -d -p 4000:4000 -v ${ZREPO}:/app --name zer0_container ${GIT_REPO}
# Start the container and run the CMD line from the Dockerfile
docker start zer0_container
# Attach to the running container
docker exec -it zer0_container /bin/bash
open http://localhost:4000/
code _config.yml
title: zer0-mistakes
email: bamr87@zer0-mistakes.com
description: >- # this means to ignore newlines until "baseurl:"
Write an awesome description for your new site here. You can edit this
line in _config.yml. It will appear in your document head meta (for
Google search results) and in your feed.xml site description.
baseurl: null # the subpath of your site, e.g. /blog
url: null # the base hostname & protocol for your site, e.g. http://example.com
twitter_username: bamr87
github_username: bamr87
def convert_md_to_files(md_file_path):
language_files = {}
language_mode = None
language_extensions = {'python': '.py', 'shell': '.sh'}
shebang_lines = {'python': '#!/usr/bin/env python3\n', 'shell': '#!/bin/bash\n'}
with open(md_file_path, 'r') as md_file:
for line in md_file:
if line.startswith('```'):
if language_mode:
# End of a language block, switch back to markdown mode
language_mode = None
else:
# Start of a language block, open a new file for this language if not already open
language = line.strip('`\n')
if language in language_extensions:
language_mode = language
if language not in language_files:
language_file = open(md_file_path.replace('.md', language_extensions[language]), 'w')
if language in shebang_lines:
language_file.write(shebang_lines[language])
language_files[language] = language_file
continue
if language_mode:
language_files[language_mode].write(line)
# Close all open language files
for language_file in language_files.values():
language_file.close()
convert_md_to_files('zer0.md')
{% include_relative _config.yml %}
FAQs
Unknown package
We found that jekyll-theme-zer0 demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
Security News
Ruby maintainers from Bundler and rbenv teams are building rv to bring Python uv's speed and unified tooling approach to Ruby development.
Security News
Following last week’s supply chain attack, Nx published findings on the GitHub Actions exploit and moved npm publishing to Trusted Publishers.