<commit_before>#!/bin/bash
# This file must be saved in UTF-8 (because of the sortcuts)

################################
# Installations Methodes
################################
function doInstallation {
	if [ -e "$C74Folder" ] ; then

		if [[ ! -e "$C74Folder/ejies" ]] ; then
			mkdir "$C74Folder/ejies";
		fi
		
		echo -ne "- objects ($C74Folder/ejies/ejies-obj)"
		cp -R "$DossierDeLInstalleur"/ejies-obj "$C74Folder/ejies/" && echo -ne "... done.\n"

		echo -ne "- help files ($C74Folder/ejies/ejies-help)"
		cp -R "$DossierDeLInstalleur"/ejies-help "$C74Folder/ejies/" && echo -ne "... done.\n"
		
		echo -ne "- init files ($C74Folder/init/)"
		cp -R "$DossierDeLInstalleur"/ejies-init/* "$C74Folder/init/" && echo -ne "... done.\n"
		
		echo -ne "- jsui files ($C74Folder/jsui-library/)"
		cp -R "$DossierDeLInstalleur"/ejies-jsui/* "$C74Folder/jsui-library/" && echo -ne "... done.\n"
		
		echo -ne "- jsextensions file ($C74Folder/jsextensions/)"
		cp -R "$DossierDeLInstalleur"/ejies-jsextensions/* "$C74Folder/jsextensions/" && echo -ne "... done.\n"
	
		echo -ne "- java lib file ($C74Folder/java/lib/ej.jar)"
		cp -R "$DossierDeLInstalleur"/ejies-java/ej.jar "$C74Folder/java/lib/" && echo -ne "... done.\n"
	else
		echo -ne "Sorry, $C74Folder doesn't exist. Init, jsui and jsextensions can't be installed.\n"
	fi
	
	if [ -e "$maxAppFolder" ] ; then
		echo -ne "- extras file ($maxAppFolder/patches/extras/)"
		cp "$DossierDeLInstalleur"/ejies-extras/ejies-overview.maxpat "$maxAppFolder/patches/extras/" && echo -ne "... done.\n"
	
		echo -ne "- prototypes ($maxAppFolder/patches/object-prototypes/)"
		cp -R "$DossierDeLInstalleur"/ejies-prototypes/* "$maxAppFolder/patches/object-prototypes/" && echo -ne "... done.\n"
	
# 		echo -ne "- inspectors ($maxAppFolder/patches/inspectors)"
# 		cp "$DossierDeLInstalleur"/ejies-insp/* "$maxAppFolder/patches/inspectors/" && echo -ne "... done.\n"
		
		echo -ne "- images ($maxAppFolder/patches/picts)"
		cp -R "$DossierDeLInstalleur"/ejies-pict/* "$maxAppFolder/patches/picts/" && echo -ne "... done.\n"
		
		echo -ne "- ejies-javadoc ($maxAppFolder/java-doc/)"
		cp -R "$DossierDeLInstalleur"/ejies-javadoc "$maxAppFolder/java-doc/" && echo -ne "... done.\n"		
	else
		echo -ne "Sorry, $maxAppFolder/ doesn't exist. Extra and prototypes can't be installed.\n"
	fi

	echo -ne "\n";
}

################################




################################
# Installation process
################################
clear
echo "------------------------"
echo "-- ejies Installation --"
echo "------------------------"
echo ""
echo ""


################################
# making PATH
################################
PathDeLInstalleur=$0
DossierDeLInstalleur=$(dirname "$PathDeLInstalleur")


################################
#  Version checking
################################
installedAtLeastOneVersion=0;

echo -ne "Checking version... ";
if [ -e "/Applications/Max5" ]; then
	maxAppFolder="/Applications/Max5";
	C74Folder="$maxAppFolder/Cycling '74";
	
	echo "Installing ejies for Max 5, in $maxAppFolder:";
	doInstallationForMax5;
	installedAtLeastOneVersion=1;
fi

if [ -e "/Applications/Max6" ]; then
	maxAppFolder="/Applications/Max6";
	C74Folder="$maxAppFolder/Cycling '74";
	
	echo "Installing ejies for Max 6, in $maxAppFolder:";
	doInstallationForMax6;
	installedAtLeastOneVersion=1;
fi

# on my C74 computer...
if [ -e "/sysbuild/Development" ]; then
	maxAppFolder="/sysbuild/Development";
	C74Folder="$maxAppFolder/Cycling '74";
	
	echo "Installing ejies for Max 6, in $maxAppFolder:";
	doInstallationForMax6;
	installedAtLeastOneVersion=1;
fi

if [[ $installedAtLeastOneVersion == 0 ]]; then
	echo "Max 5 or 6 is not installed in the /Applications folder. The ejies's automatic installation is not possible. Sorry...";
	exit 1;
fi
<commit_msg>updated script for Max 5 and Max 6 support... for real<commit_after>#!/bin/bash
# This file must be saved in UTF-8 (because of the sortcuts)

################################
# Installations Methodes
################################
function doInstallation {
	if [ -e "$C74Folder" ] ; then

		if [[ ! -e "$C74Folder/ejies" ]] ; then
			mkdir "$C74Folder/ejies";
		fi
		
		echo -ne "- objects ($C74Folder/ejies/ejies-obj)"
		cp -R "$DossierDeLInstalleur"/ejies-obj "$C74Folder/ejies/" && echo -ne "... done.\n"

		echo -ne "- help files ($C74Folder/ejies/ejies-help)"
		cp -R "$DossierDeLInstalleur"/ejies-help "$C74Folder/ejies/" && echo -ne "... done.\n"
		
		echo -ne "- init files ($C74Folder/init/)"
		cp -R "$DossierDeLInstalleur"/ejies-init/* "$C74Folder/init/" && echo -ne "... done.\n"
		
		echo -ne "- jsui files ($C74Folder/jsui-library/)"
		cp -R "$DossierDeLInstalleur"/ejies-jsui/* "$C74Folder/jsui-library/" && echo -ne "... done.\n"
		
		echo -ne "- jsextensions file ($C74Folder/jsextensions/)"
		cp -R "$DossierDeLInstalleur"/ejies-jsextensions/* "$C74Folder/jsextensions/" && echo -ne "... done.\n"
	
		echo -ne "- java lib file ($C74Folder/java/lib/ej.jar)"
		cp -R "$DossierDeLInstalleur"/ejies-java/ej.jar "$C74Folder/java/lib/" && echo -ne "... done.\n"
	else
		echo -ne "Sorry, $C74Folder doesn't exist. Init, jsui and jsextensions can't be installed.\n"
	fi
	
	if [ -e "$maxAppFolder" ] ; then
		echo -ne "- extras file ($maxAppFolder/patches/extras/)"
		cp "$DossierDeLInstalleur"/ejies-extras/ejies-overview.maxpat "$maxAppFolder/patches/extras/" && echo -ne "... done.\n"
	
		echo -ne "- prototypes ($maxAppFolder/patches/object-prototypes/)"
		cp -R "$DossierDeLInstalleur"/ejies-prototypes/* "$maxAppFolder/patches/object-prototypes/" && echo -ne "... done.\n"
	
# 		echo -ne "- inspectors ($maxAppFolder/patches/inspectors)"
# 		cp "$DossierDeLInstalleur"/ejies-insp/* "$maxAppFolder/patches/inspectors/" && echo -ne "... done.\n"
		
		echo -ne "- images ($maxAppFolder/patches/picts)"
		cp -R "$DossierDeLInstalleur"/ejies-pict/* "$maxAppFolder/patches/picts/" && echo -ne "... done.\n"
		
		echo -ne "- ejies-javadoc ($maxAppFolder/java-doc/)"
		cp -R "$DossierDeLInstalleur"/ejies-javadoc "$maxAppFolder/java-doc/" && echo -ne "... done.\n"		
	else
		echo -ne "Sorry, $maxAppFolder/ doesn't exist. Extra and prototypes can't be installed.\n"
	fi

	echo -ne "\n";
}

################################




################################
# Installation process
################################
clear
echo "------------------------"
echo "-- ejies Installation --"
echo "------------------------"
echo ""
echo ""


################################
# making PATH
################################
PathDeLInstalleur=$0
DossierDeLInstalleur=$(dirname "$PathDeLInstalleur")


################################
#  Version checking
################################
installedAtLeastOneVersion=0;

echo -ne "Checking version... ";
if [ -e "/Applications/Max5" ]; then
	maxAppFolder="/Applications/Max5";
	C74Folder="$maxAppFolder/Cycling '74";
	
	echo "Installing ejies for Max 5, in $maxAppFolder:";
	doInstallation;
	installedAtLeastOneVersion=1;
fi

if [ -e "/Applications/Max6" ]; then
	maxAppFolder="/Applications/Max6";
	C74Folder="$maxAppFolder/Cycling '74";
	
	echo "Installing ejies for Max 6, in $maxAppFolder:";
	doInstallation;
	installedAtLeastOneVersion=1;
fi

# on my C74 computer...
if [ -e "/sysbuild/Development" ]; then
	maxAppFolder="/sysbuild/Development";
	C74Folder="$maxAppFolder/Cycling '74";
	
	echo "Installing ejies for Max 6, in $maxAppFolder:";
	doInstallation;
	installedAtLeastOneVersion=1;
fi

if [[ $installedAtLeastOneVersion == 0 ]]; then
	echo "Max 5 or 6 is not installed in the /Applications folder. The ejies's automatic installation is not possible. Sorry...";
	exit 1;
fi

{'fraction_non_alphanumeric': 0.24097803347280336, 'fraction_numerical': 0.01712866108786611, 'mean_word_length': 3.7450372208436726, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 4, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3057268', 'n_tokens_mistral': 2877, 'n_tokens_neox': 2532, 'n_words': 602}