fix-line-endings-check-bash

Normalize CRLF to LF and validate Bash script syntax.

3|Updated Oct 17, 2025
One-click install
npx skills add https://github.com/ManuelKugelmann/BitBot --skill fix-line-endings-check-bash
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: fix-line-endings-check-bash
Source: https://github.com/ManuelKugelmann/BitBot/tree/main/.bitbot/internal/container/templates/bitbot-dev/.claude/skills/fix-line-endings-check-bash
Command: npx skills add https://github.com/ManuelKugelmann/BitBot --skill fix-line-endings-check-bash

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve?

Streamlines the preparation of bash scripts by combining two essential steps: fixing line ending inconsistencies and validating syntax. This ensures scripts are robust and error-free before deployment.

Core Features & Use Cases

  • Dual-Action Utility: Converts CRLF to LF line endings and then performs a syntax check.
  • Pre-Deployment Assurance: Guarantees scripts are correctly formatted and syntactically sound.
  • Use Case: After writing a new bash script, run this skill to automatically clean up any Windows line endings and confirm there are no syntax errors, making it ready for use on Linux.

Quick Start

Fix line endings and check syntax for 'build.sh'. .claude/skills/fix-line-endings-check-bash/scripts/fix-line-endings-check-bash.sh build.sh

Frequently Asked Questions about fix-line-endings-check-bash

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I fix line endings in bash scripts?

Fix line endings by converting CRLF (Windows format) to LF (Unix format) using dos2unix or sed. This Skill automates that conversion and validates syntax in a single step, ensuring scripts run correctly on Linux systems without line-ending errors.

Can I check bash script syntax before running it?

Yes, syntax checking validates bash scripts using bash -n without executing them. This Skill combines syntax validation with line-ending normalization, catching errors early and confirming the script is syntactically sound before deployment.

What's the best way to prepare bash scripts for Linux deployment?

Prepare scripts by normalizing line endings to LF and validating syntax. This Skill performs both steps automatically, eliminating Windows line-ending issues and syntax errors in one pass, making scripts ready for immediate use on Linux servers.

Do line endings matter in bash scripts?

Yes, line endings matter significantly. Windows line endings (CRLF) can cause "command not found" errors and unexpected behavior in bash scripts on Unix systems. Converting to LF ensures consistent execution across platforms.

How do I process multiple bash scripts at once?

This Skill handles multiple files in a single invocation, reporting results per file and exiting with success or failure status. Pass multiple script filenames to fix line endings and validate syntax across all files simultaneously.

What happens if a bash script has syntax errors?

The Skill stops at the first syntax error and reports it, exiting with status 1. This fail-fast behavior prevents deploying broken scripts and helps you identify and fix issues before they cause problems in production.