diff --git a/README.md b/README.md index 01d4187..52a856b 100644 --- a/README.md +++ b/README.md @@ -12,7 +12,7 @@ Elsewhere, consider it released under the [WTFPLv2](http://www.wtfpl.net/txt/cop Depends on [tmux](http://github.com/tmux/tmux). Uses [JSON.sh](http://github.com/dominictarr/JSON.sh). -For full UTF-8 support you need [python on your system](doc/4_expert.md#UTF-8-Support) (optional). +Most complete [UTF-8 support for bashbot](doc/4_expert.md#Bashbot-UTF-8-Support) is availible if phyton is installed (optional). Bashbot [Documentation](https://github.com/topkecleon/telegram-bot-bash) and [Downloads](https://github.com/topkecleon/telegram-bot-bash/releases) are availible on www.github.com @@ -57,14 +57,16 @@ Bashbot [Documentation](https://github.com/topkecleon/telegram-bot-bash) and [Do From Version 0.60 on keybord format for ```send_keyboard``` and ```send_message "mykeyboardstartshere ..."``` was changed. Keybords are now defined in JSON Array notation e.g. "[ \\"yes\\" , \\"no\\" ]". This has the advantage that you can create any type of keyboard supported by Telegram. -The old format is supported for backward compatibility, but may fail for strange corner cases. +The old format is supported for backward compatibility, but may fail for corner cases. *Example Keyboards*: -- OLD format: 'yes' 'no' (two strings) -- NEW format: '[ "yes" , "no" ]' (string containing an array) -- new keybord layouts, not possible with old format: - - Yes No in two rows: '[ "yes" ] , [ "no" ]' +- yes no in two rows: + - OLD format: 'yes' 'no' (two strings) + - NEW format: '[ "yes" ] , [ "no" ]' (two arrays with a string) +- new layouts made easy with NEW format: + - Yes No in one row: '[ "yes" , "no" ]' + - Yes No plus Maybe in 2.row: '[ "yes" , "no" ] , [ "maybe" ]' - numpad style keyboard: '[ "1" , "2" , "3" ] , [ "4" , "5" , "6" ] , [ "7" , "8" , "9" ] , [ "0" ]' ## Security Considerations @@ -97,4 +99,4 @@ Bashbot is not more (in)secure as any other Bot written in any other language, w If you feel that there's something missing or if you found a bug, feel free to submit a pull request! -#### $$VERSION$$ v0.60-rc3-0-g19a0f7e +#### $$VERSION$$ v0.60-0-gf5162e2 diff --git a/README.txt b/README.txt index 1dc7eaa..8efb506 100644 --- a/README.txt +++ b/README.txt @@ -80,14 +80,16 @@ From Version 0.60 on keybord format for `send_keyboard` and defined in JSON Array notation e.g. "[ \"yes\" , \"no\" ]". This has the advantage that you can create any type of keyboard supported by Telegram. The old format is supported for backward compatibility, but -may fail for strange corner cases. +may fail for corner cases. _Example Keyboards_: -* OLD format: 'yes' 'no' (two strings) -* NEW format: '[ "yes" , "no" ]' (string containing an array) -* new keybord layouts, not possible with old format: -** Yes No in two rows: '[ "yes" ] , [ "no" ]' +* yes no in two rows: +** OLD format: 'yes' 'no' (two strings) +** NEW format: '[ "yes" ] , [ "no" ]' (two arrays with a string) +* new layouts made easy with NEW format: +** Yes No in one row: '[ "yes" , "no" ]' +** Yes No plus Maybe in 2.row: '[ "yes" , "no" ] , [ "maybe" ]' ** numpad style keyboard: '[ "1" , "2" , "3" ] , [ "4" , "5" , "6" ] , [ "7" , "8" , "9" ] , [ "0" ]' @@ -159,5 +161,5 @@ That's it! If you feel that there's something missing or if you found a bug, feel free to submit a pull request! -latexmath:[\[VERSION\]] v0.60-rc3-0-g19a0f7e -++++++++++++++++++++++++++++++++++++++++++++ +latexmath:[\[VERSION\]] v0.60-0-gf5162e2 +++++++++++++++++++++++++++++++++++++++++ diff --git a/bashbot.cron b/bashbot.cron index 502c7b6..e5aa77e 100644 --- a/bashbot.cron +++ b/bashbot.cron @@ -7,7 +7,7 @@ # This file is public domain in the USA and all free countries. # Elsewhere, consider it to be WTFPLv2. (wtfpl.net/txt/copying) # -#### $$VERSION$$ v0.60-rc3-0-g19a0f7e +#### $$VERSION$$ v0.60-0-gf5162e2 SHELL=/bin/sh diff --git a/bashbot.rc b/bashbot.rc index 5361ac4..58deb15 100755 --- a/bashbot.rc +++ b/bashbot.rc @@ -1,7 +1,7 @@ #!/bin/sh # description: Start or stop telegram-bash-bot # -#### $$VERSION$$ v0.60-rc3-0-g19a0f7e +#### $$VERSION$$ v0.60-0-gf5162e2 # shellcheck disable=SC2009 # shellcheck disable=SC2181 diff --git a/bashbot.sh b/bashbot.sh index b84c82f..8376553 100755 --- a/bashbot.sh +++ b/bashbot.sh @@ -10,7 +10,7 @@ # This file is public domain in the USA and all free countries. # Elsewhere, consider it to be WTFPLv2. (wtfpl.net/txt/copying) # -#### $$VERSION$$ v0.60-rc3-0-g19a0f7e +#### $$VERSION$$ v0.60-0-gf5162e2 # # Exit Codes: # - 0 sucess (hopefully) diff --git a/calc b/calc index c5e9135..b35eb40 100755 --- a/calc +++ b/calc @@ -3,7 +3,7 @@ # This file is public domain in the USA and all free countries. # Elsewhere, consider it to be WTFPLv2. (wtfpl.net/txt/copying) -#### $$VERSION$$ v0.60-rc3-0-g19a0f7e +#### $$VERSION$$ v0.60-0-gf5162e2 # adjust your language setting here # https://github.com/topkecleon/telegram-bot-bash#setting-up-your-environment diff --git a/commands.sh b/commands.sh index c70a39d..7c3f0fa 100755 --- a/commands.sh +++ b/commands.sh @@ -4,7 +4,7 @@ # This file is public domain in the USA and all free countries. # Elsewhere, consider it to be WTFPLv2. (wtfpl.net/txt/copying) # -#### $$VERSION$$ v0.60-rc3-0-g19a0f7e +#### $$VERSION$$ v0.60-0-gf5162e2 # # shellcheck disable=SC2154 # shellcheck disable=SC2034 diff --git a/doc/1_firstbot.md b/doc/1_firstbot.md index 7c92642..4fe1822 100644 --- a/doc/1_firstbot.md +++ b/doc/1_firstbot.md @@ -61,5 +61,5 @@ group. This step is up to you actually. #### [Next Getting started](2_usage.md) -#### $$VERSION$$ v0.60-rc3-0-g19a0f7e +#### $$VERSION$$ v0.60-0-gf5162e2 diff --git a/doc/2_usage.md b/doc/2_usage.md index e04b367..cfd993d 100644 --- a/doc/2_usage.md +++ b/doc/2_usage.md @@ -159,5 +159,5 @@ send_action "${CHAT[ID]}" "action" #### [Prev Create Bot](1_firstbot.md) #### [Next Advanced Usage](3_advanced.md) -#### $$VERSION$$ v0.60-rc3-0-g19a0f7e +#### $$VERSION$$ v0.60-0-gf5162e2 diff --git a/doc/3_advanced.md b/doc/3_advanced.md index 6bc50bc..48155e8 100644 --- a/doc/3_advanced.md +++ b/doc/3_advanced.md @@ -156,5 +156,5 @@ answer_inline_query "$iQUERY_ID" "cached_sticker" "identifier for the sticker" #### [Prev Advanced Usage](3_advanced.md) #### [Next Expert Use](4_expert.md) -#### $$VERSION$$ v0.60-rc3-0-g19a0f7e +#### $$VERSION$$ v0.60-0-gf5162e2 diff --git a/doc/4_expert.md b/doc/4_expert.md index 26d7b74..67391da 100644 --- a/doc/4_expert.md +++ b/doc/4_expert.md @@ -37,7 +37,7 @@ export 'LANGUAGE=den_US.UTF-8' To display all availible locales on your system run ```locale -a | more```. [Gentoo Wiki](https://wiki.gentoo.org/wiki/UTF-8) -#### Bashbot's UTF-8 Support +#### Bashbot UTF-8 Support Bashbot handles all messages transparently, regardless of the charset in use. The only exception is when converting from JSON data to strings. Telegram use JSON to send / recieve data. JSON encodes strings as follow: Characters not ASCII *(>127)* are escaped as sequences of ```\uxxxx``` to be regular ASCII. In addition multibyte characters, *e.g. Emoticons or Arabic characters*, are send in double byte UTF-16 notation. @@ -45,8 +45,8 @@ The Emoticons ``` 😁 😘 ❤️ 😊 👍 ``` are encoded as: ``` \uD83D\uDE0 **This "mixed" JSON encoding needs special handling and can not decoded from** ```echo -e``` or ```printf '%s\\n'``` -To to fully support decoding of multibyte characters you need a working python2 installation on your system. -If no python is detected bashbot falls back to a **internal pure bash implementaion which may not work for some corner cases**. +Most complete support for decoding of multibyte characters can only be provided if python is installed on your system. +**Without phyton bashbot falls back to an internal, pure bash implementation which may not work for some corner cases**. ### Run as other user or system service @@ -104,5 +104,5 @@ An example crontab is provided in ```bashbot.cron```. #### [Prev Expert Use](4_expert.md) #### [Next Best Practice](5_practice.md) -#### $$VERSION$$ v0.60-rc3-0-g19a0f7e +#### $$VERSION$$ v0.60-0-gf5162e2 diff --git a/doc/5_practice.md b/doc/5_practice.md index 6b640ab..b24b577 100644 --- a/doc/5_practice.md +++ b/doc/5_practice.md @@ -112,5 +112,5 @@ The second warning is about an unused variable, this is true because in our exam #### [Prev Best Practice](5_practice.md) #### [Next Functions Reference](6_reference.md) -#### $$VERSION$$ v0.60-rc3-0-g19a0f7e +#### $$VERSION$$ v0.60-0-gf5162e2 diff --git a/doc/6_reference.md b/doc/6_reference.md index a84ec9d..5419742 100644 --- a/doc/6_reference.md +++ b/doc/6_reference.md @@ -117,13 +117,14 @@ send_file "${CHAT[ID]}" "https://www.domain,com/something.gif" "Something" ##### send_keyboard Note: since version 0.6 send_keyboard was changed to use native "JSON Array" notation as used from Telegram. Example Keybord Array definitions: -- OLD format: 'yes' 'no' (two strings) -- NEW format: '[ "yes" , "no" ]' (string containing an array) -- new keybord layouts, not possible with old format: - - Yes No in two rows: '[ "yes" ] , [ "no" ]' +- yes no in two rows: + - OLD format: 'yes' 'no' (two strings) + - NEW format: '[ "yes" ] , [ "no" ]' (two arrays with a string) +- new layouts made easy with NEW format: + - Yes No in one row: '[ "yes" , "no" ]' + - Yes No plus Maybe in 2.row: '[ "yes" , "no" ] , [ "maybe" ]' - numpad style keyboard: '[ "1" , "2" , "3" ] , [ "4" , "5" , "6" ] , [ "7" , "8" , "9" ] , [ "0" ]' - *usage:* send_keyboard "chat-id" "message" "keyboard" *example:* @@ -346,5 +347,5 @@ Send Input from Telegram to waiting Interactive Chat. #### [Prev Best Practice](5_practice.md) -#### $$VERSION$$ v0.60-rc3-0-g19a0f7e +#### $$VERSION$$ v0.60-0-gf5162e2 diff --git a/notify b/notify index c2010e5..56da2ac 100755 --- a/notify +++ b/notify @@ -2,7 +2,7 @@ # This file is public domain in the USA and all free countries. # Elsewhere, consider it to be WTFPLv2. (wtfpl.net/txt/copying) -#### $$VERSION$$ v0.60-rc3-0-g19a0f7e +#### $$VERSION$$ v0.60-0-gf5162e2 # adjust your language setting here # https://github.com/topkecleon/telegram-bot-bash#setting-up-your-environment diff --git a/question b/question index 5b51f26..c1dc69b 100755 --- a/question +++ b/question @@ -3,7 +3,7 @@ # This file is public domain in the USA and all free countries. # Elsewhere, consider it to be WTFPLv2. (wtfpl.net/txt/copying) -#### $$VERSION$$ v0.60-rc3-0-g19a0f7e +#### $$VERSION$$ v0.60-0-gf5162e2 # adjust your language setting here # https://github.com/topkecleon/telegram-bot-bash#setting-up-your-environment diff --git a/version b/version index bd6b524..bad3f2f 100755 --- a/version +++ b/version @@ -1,6 +1,6 @@ #!/bin/bash # -#### $$VERSION$$ v0.60-rc3-0-g19a0f7e +#### $$VERSION$$ v0.60-0-gf5162e2 # shellcheck disable=SC2016 # # Easy Versioning in git: