Created
December 18, 2011 21:58
-
-
Save emres/1494606 to your computer and use it in GitHub Desktop.
Language detection in Bash command line
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
en_res=$(echo $(cat some_en.txt EN | gzip | wc -c) - $(gzip -c EN | wc -c) | bc); \ | |
de_res=$(echo $(cat some_en.txt DE | gzip | wc -c) - $(gzip -c DE | wc -c) | bc); \ | |
(echo $en_res EN && echo $de_res DE) | sort -n | head -1 | cut -d' ' -f2 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I get the following error in Ubuntu 20.04:
Is there another easy linux command to detect language output ?