Skip to content
This repository has been archived by the owner on Jul 28, 2023. It is now read-only.

Commit

Permalink
Merge pull request #1 from spaceonfire/bundle_mp-iconv
Browse files Browse the repository at this point in the history
WIP: some improvements for iconv
  • Loading branch information
hustlahusky authored Oct 30, 2018
2 parents 747510a + ff5d24b commit 183012b
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
2 changes: 1 addition & 1 deletion bin/bundle
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,4 @@ if [ -e .bmfignore ]; then
ignore="-X .bmfignore"
fi

tar -czf $name ./* $ignore
tar $ignore -czf $name ./*
9 changes: 7 additions & 2 deletions bin/bundle_mp
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,19 @@ cp -r ./* .last_version
chown -R 1000.1000 .last_version

# Convert encoding for lang files
find ./.last_version -name "*.php" -path "*lang*" -exec iconv -f utf-8 -t windows-1251 {} -o {} \;
find ./.last_version -name "*.php" -path "*lang*" | while read i;
do
echo $i
iconv -f utf-8 -t windows-1251 "$i" > tmp; \
mv tmp "$i";
done

if [ -e .bmfignore ]; then
ignore="-X .bmfignore"
fi

# Create bundle
tar -czf .last_version.tar.gz .last_version $ignore
tar $ignore -czf .last_version.tar.gz .last_version

# Little clean up
rm -rf .last_version

0 comments on commit 183012b

Please sign in to comment.