1 If you are commit to the i18n-zh project repository, please read this first.
3 ============================================
4 Guide to i18n-zh project repository
5 ============================================
8 * Software version requirements
10 * Repository on repo.or.cz
11 * Repository maintenance
12 * Common git operation
13 * Getting the latest upstream code
16 * File permission & encoding
17 * Verifying your po file
18 * Formating your po file
33 Software version requirements
34 =============================
37 *) translate-toolkit(pomerge & pofilter) 1.0.1
42 The flowwing is the sample configuration, please modify some fields.
61 # email = dongsheng.song@gmail.com
62 # name = Dongsheng Song
66 # HostName 152.69.94.80
71 Repository on repo.or.cz
72 ========================
75 http://repo.or.cz/w/i18n-zh.git
79 # cat .git/branches/origin
81 git://repo.or.cz/i18n-zh.git
82 http://repo.or.cz/r/i18n-zh.git
86 git+ssh://repo.or.cz/srv/git/i18n-zh.git
89 Repository maintenance
93 git-repack -a -d -f --window=128 --depth=64
97 git-fsck --unreachable --strict HEAD $(cat .git/refs/heads/*)
104 git-clone git://repo.or.cz/i18n-zh.git
108 "git-pull -v" or "git fetch", See section "Getting the latest upstream code".
111 git-checkout -f filename
115 git-commit -a -m "your log messages"
117 if you commit patch by someone, use option "--author":
119 git-commit -a --author someone -m "your log messages"
123 git reset --soft HEAD^
127 git-push git+ssh://repo.or.cz/srv/git/i18n-zh.git master:master
130 Getting the latest upstream code
131 ================================
132 There are two ways to update your local repository. Which one to use depends on
133 whether you have committed changes in the meantime.
137 The command to update your local repository is:
141 It will pull down the latest repository information from the origin remote
142 file (which points at where you initially cloned the repository from), then
143 merge. If the new changes don't conflict with anything locally, the merge
144 will "fast-forward" your branch reference to the new head. If new changes
145 do conflict, it will try to do an automatic merge using a couple of
146 different schemes, and then automatically commits the merge if it's
147 satisfied. If you notice that your pull resulted in a merge (in the output
148 of pull), you might want to use gitk to see if the merge did what you
149 expected it to. If it isn't satisfied, then you have to resolve the
152 *) You've made changes: fetch and rebase
154 If you have committed local changes, then git-pull will create a spurious
155 "Merge" commit, which will pollute the change list when you later push
156 upstream. To avoid this, do these two commands:
161 Instead of merging, this attempts to insert the changes you pull from the
162 origin repository before your local changes, avoiding the merge message.
167 *) Clone a repo (like git clone)
169 git-svn clone -T trunk -b branches -t tags https://i18n-zh.googlecode.com/svn/trunk
171 *) Reset your master to trunk (or any other branch)
173 git reset --hard remotes/trunk
175 *) Do some work and commit locally to git
179 *) Something is committed to SVN, rebase your local changes against the latest
184 *) Now commit your changes (that were committed previously using git) to SVN,
185 as well as automatically updating your working HEAD:
193 diff -wBNr -x .git . i18n-zh.origin
196 patch -p0 < zh_CN.patch
199 File permission & encoding
200 ==========================
203 set umask to 002, i.e.
205 set directory to 0775
206 set common file to 0664
207 set execute file to 0775
210 using utf-8 without signature(no BOM)
213 Verifying your po file
214 ======================
215 Please verify your po file is valid:
217 msgfmt --check-accelerators --statistics -c -o zh_CN.mo zh_CN.po
220 Formating your po file
221 ======================
222 Please format your translation before send po to the mailing list,
223 or commit to the repository.
225 msgmerge --no-wrap -F -o zh_CN-new.po zh_CN.po example.pot
226 mv -f zh_CN-new.po zh_CN.po
228 This can minimize the diff output, review your translation is easy.