File update

Fixed some numerical issues in sed command
This commit is contained in:
Nassim Bentarka 2018-02-14 21:29:43 +00:00 committed by GitHub
parent d34cd8dfc2
commit e29128ef83
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 4 deletions

View File

@ -1,19 +1,20 @@
#!/bin/sh
#!/bin/bash
#az_qw_converter.sh by ptinaze for THC
#az_qw_convert.sh - Enhanced by NBN - (Case sensitive input)
echo "Do you want to convert :\n\n1. QWERTY to AZERTY\n2. AZERTY to QWERTY"; read chx
if test "$chx" -eq "1"; then
sleep 1
echo "Please, insert the text you want to convert in AZERTY"; read txt
sleep 1
sleep .5
echo "$txt" | sed 'y/qQaAzZwWmM,<.;:/aAqQwWzZ,?;.:mM/' | sed "y/4'/'ù/" | sed 'y/123567890-_!@#$%^&*()[{]}¦"?/&é"(-è_çà)°1234567890^¨$£µ%§/' | sed 'y/>\\\//\/*!/'
elif test "$chx" -eq "2"; then
sleep 1
echo "Please, insert the text you want to convert in QWERTY"; read txt
sleep 1
echo "$txt" | sed 'y/aAqQwWzZ,?;.:mM/qQaAzZwWmM,<.;:/' | sed 'y/!\//\/>/' | sed 'y/&é"(-è_çà)°123567890^¨$£*µ%§/123567890-_!@#$%^&*()[{]}\¦"?/' | sed "y/ù'/'4/"
sleep .5
echo "$txt" | sed 'y/aAqQwWzZ,?;.:mM/qQaAzZwWmM,<.;:/' | sed "y/!\//\/>/" | sed 'y/&é"(-è_çà)°1234567890^¨$£µ%§/123567890-_!@#$%^&*()[{]}¦"?/' | sed "y/ù'/'4/"
else
exit
fi