#!/bin/bash # Check if the current directory is already a git repository if [ -d ".git" ]; then echo "Error: Git repository already exists." exit 1 fi # Create .gitignore file cat < .gitignore * !*.mqh !*.mq5 !*.mq4 !*/ !**/*.mqh !**/*.mq5 !**/*.mq4 EOL # Initialize git repository git init # Add all files to the staging area git add . # Count how many files are in the index file_count=$(git ls-files | wc -l) echo "Number of files in the index: $file_count" # Execute the command to check eolinfo for files in the index git ls-files --format='%(eolinfo:index) %(path)' | column -t | grep '\-text'