Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Add pre-commit config; update RELEASE-NOTES.txt
  • Loading branch information
definite committed Nov 10, 2016
1 parent 0aac742 commit d3e13b9
Show file tree
Hide file tree
Showing 5 changed files with 105 additions and 40 deletions.
24 changes: 0 additions & 24 deletions README

This file was deleted.

28 changes: 28 additions & 0 deletions README.md
@@ -0,0 +1,28 @@
IBus-Chewing is an IBus front-end of Chewing, an intelligent Chinese input
method for Zhuyin (BoPoMoFo) users.

Following documents provides further instruction:

COPYING : GPLv2 Licence
USER-GUIDE: How to use ibus-chewing
INSTALL : Installation instruction.

Bugs and enhancement can be filed to either:
* [Red Hat Bugzilla](https://bugzilla.redhat.com/enter_bug.cgi?product=Fedora&component=ibus-chewing)
* [GitHub ibus-chewing](https://github.com/definite/ibus-chewing/issues)

We use [K&R coding style](https://en.wikipedia.org/wiki/Indent_style#K.26R_style) to make our review easier, so if you like to contribute, please set the git pre-commit hook by:
```sh
ln -s ../../pre-commit .git/hooks/pre-commit
```

For debugging ibus-chewing:
1. Quit existing ibus-daemon
By right click on IBus systray icon, then quit, or kill the process.
2. Edit `/usr/share/ibus/component/chewing.xml`, add `-v 7`
to turn verbose level 7
3. Run ibus-daemon in command line with following command
```
export G_MESSAGES_DEBUG=all
ibus-daemon -rvx
```
21 changes: 5 additions & 16 deletions RELEASE-NOTES.txt
@@ -1,19 +1,8 @@
PRJ_VER=1.5.1
SUMMARY=Fix the Ctrl, Numpad and selection keys handling
REDHAT_BUGZILLA=1337185
PRJ_VER=1.5.2
SUMMARY=
REDHAT_BUGZILLA=
[Changes]
- Enhancement:
- Fix:
+ GH issue #73: Ctrl, Alt, Ins causes the pre-edit duplicate commit
+ GH issue #74: Failed to clean the PreEdit when changing input focus
+ GH issue #79: Failed to input space when "space-as-selection"
+ GH issue #87 Modify dropdown menu for selecting keys
+ GH issue #88 Numpad should be able to select
+ RHBZ #1337185 - Cannot add phrases with Ctrl
A.k.a GH issue #63
Thank for contribution from hiunnhue
- Acknowledge:
+ Obata Akio contributed pull request 71, 72, 73
+ hiunnhue contributed pull request 75, 76, 77, 78, 80, 81, 82, 83, 84, 86,
87, 90, 91, 92, 94
+ hiunnhue fixed issue 73, 74, 79, 87, 88, 90, 91, 92, 94
+ GitHub Issue: #35 Support KB_THL_PINYIN and KB_MPS2_PINYIN
+ GitHub Issue: #93 Remove XTST from CMakeLists.txt
49 changes: 49 additions & 0 deletions pre-commit
@@ -0,0 +1,49 @@
#!/bin/bash -eu
#
# An example hook script to verify what is about to be committed.
# Called by "git commit" with no arguments. The hook should
# exit with non-zero status after issuing an appropriate message if
# it wants to stop the commit.
#
# To enable this hook, rename this file to "pre-commit".


function exit_print_error(){
if [[ -z $Indent ]];then
echo "Please install 'indent' and put it in system PATH," > /dev/stderr
echo "or specify it in 'git config hooks.indent'" > /dev/stderr
exit 1
fi
}

trap exit_print_error EXIT
Indent="$(git config hooks.indent)" || Indent=$(which indent 2>/dev/null)

if git rev-parse --verify HEAD >/dev/null 2>&1; then
Against=HEAD
else
# Initial commit: diff against an empty tree object
Against=$(git hash-object -t tree /dev/null)
fi

## Loop on modified files
while read File; do
if [[ ! -r $File ]];then
continue
fi

## Assume we do not have files named "c" or "h"
Ext=${File##*.}
case $Ext in
c|h)
echo "Indenting " $File > /dev/stderr
"$Indent" -kr "$File"
;;
esac
echo "Chopping " $File > /dev/stderr
sed -r -i -e 's/[[:blank:]]+$//' $File
git add "$File"
done < <(git diff --cached --name-only $Against)

# If there are whitespace errors, print the offending file names and fail.
git diff-index --check --cached $Against -- > /dev/stderr
23 changes: 23 additions & 0 deletions src/MakerDialogUtil.h
Expand Up @@ -19,13 +19,36 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/

/**
* SECTION:MakerDialogUtil.h
* @short_description: Utility functions for MakerDialog
* @title: MakerDialog Util
* @stability: Stable
* @include: MakerDialogUtil.h
*
* Utility functions for MakerDialog.
* The functions have <emphasis>mkdg_</emphasis> prefix,
* while definitions have <emphasis>Mkdg</emphasis> prefix.
*/

#ifndef _MAKER_DIALOG_UTIL_H_
#define _MAKER_DIALOG_UTIL_H_
#include <ctype.h>
#include <stdio.h>
#include <string.h>
#include <glib-object.h>

/**
* MkdgLogLevel:
* @ERROR: Show auses of failure, the program should stop
* @WARN: Show issues to be address, the program will still run.
* @MSG: Show normal message
* @INFO: Show information message
* @DEBUG: Show debug message
*
* Message verbose level, from low to high. Similar to Log level of Gtk.
*
*/
typedef enum {
ERROR,
WARN,
Expand Down

0 comments on commit d3e13b9

Please sign in to comment.