catalinux / Conn (public) (License: LGPLv2) (since 2016-03-01) (hash sha1)
Net library for easy building ipv4/ipv6 network daemons/clients
List of commits:
Subject Hash Author Date (UTC)
Duilder updates. 1b717c718189468006ff0e7fb228571e76fb97e6 Catalin(ux) M. BOIE 2009-12-07 12:49:55
Exported Conn_engine_set function. 1c69de5306d302fcd6b3e6351d3e28771b08bb05 Catalin(ux) M. BOIE 2009-11-12 15:18:40
Bumped up the version to 1.0.29. ee219d6016983a64187cfe0866c597419f464535 Catalin(ux) M. BOIE 2009-09-18 12:07:41
Fix Conn_poll(-1)! Stupid me! 4ce77092baec7cbbfcd8d943838aa7eeefedbc8e Catalin(ux) M. BOIE 2009-09-18 12:07:04
Bump up the version to 1.0.28. deea1515d967c7b0708e25fe146799a09c5c2dc8 Catalin(ux) M. BOIE 2009-09-18 11:15:46
Do poll in 1000ms steps, even if Conn_poll is called with != 1 value. Else, triggers are not called! 59b4d5d8db5a4a9048f61ad836e67c824bb1ac95 Catalin(ux) M. BOIE 2009-09-18 11:15:04
Bumbed up the version to 1.0.27. 62ffc3a45094bd4b2d345d7ba37c862e1605050c Catalin(ux) M. BOIE 2009-09-18 09:43:03
More clear what error message is. acd5309c8de872f618a1055258614cf542dadf51 Catalin(ux) M. BOIE 2009-09-18 09:42:38
Compact totals. e85a25c33e9f716317932b6ee7f4b3ae6c459ff9 Catalin(ux) M. BOIE 2009-09-18 09:37:19
Cosmetic changes. 14da1b82e17275b6869493fa15e931536b77e547 Catalin(ux) M. BOIE 2009-09-18 09:31:23
Log also how many pending connections are after trytoconnect call. 4cd341f53a426cb49e437a46388b586913c0c859 Catalin(ux) M. BOIE 2009-09-18 09:30:47
Bumped up the version to 1.0.26. 2c68c221bf5ef3f5a0779e94c0448231b9fd630f Catalin(ux) M. BOIE 2009-09-18 08:31:14
Fixed a bug regarding work_to_do (decrementing on bind errors). 8b8585685bdd07d0e1df9a7ca9e41ecca9cc73bf Catalin(ux) M. BOIE 2009-09-18 08:30:10
Log also commit function. c920c0191bebc71b18bc318803db7f02ddc7b77f Catalin(ux) M. BOIE 2009-09-18 08:21:53
Log also work_to_do. a7c800b63e6ca4384726c7269e097c4f76f9991e Catalin(ux) M. BOIE 2009-09-18 07:51:26
Conn_eat logs also the slot. f65411260656b348ea34da12e7bbcbe62d7350f6 Catalin(ux) M. BOIE 2009-09-18 07:47:10
More logging in hang-up case. 325c292c46f8deb6e621836f16dec2d43cc5aea9 Catalin(ux) M. BOIE 2009-09-18 07:30:39
Bumbed up the version to 1.0.25. 379d8e2aa9df2b504cc5f539981fecf0d882c509 Catalin(ux) M. BOIE 2009-09-17 14:47:48
Lots of bulk changes to work-around C pointer change. bf3d2ae7af927b3624c4685c72ca6fa812bca640 Catalin(ux) M. BOIE 2009-09-17 14:47:19
Bumped version to 1.0.24. 77e8249758effc45a86d66f8edc5973f11a5b6f9 Catalin(ux) M. BOIE 2009-09-17 12:20:16
Commit 1b717c718189468006ff0e7fb228571e76fb97e6 - Duilder updates.
Author: Catalin(ux) M. BOIE
Author date (UTC): 2009-12-07 12:49
Committer name: Catalin(ux) M. BOIE
Committer date (UTC): 2009-12-07 12:49
Parent(s): 1c69de5306d302fcd6b3e6351d3e28771b08bb05
Signing key:
Tree: bb1c1fcd21e0caed4c343666ac49ca34b1d9a67e
File Lines added Lines deleted
duilder 112 31
File duilder changed (mode: 100755) (index 8fcd888..bf888f6)
2 2
3 3 set -e set -e
4 4
5 function git_last_changelog()
6 {
7 changelog=""
8
9 # get the list of tags
10 i=0
11 number_of_tags=0
12 for tag in `git tag -l`; do
13 if [ "${tag:0:1}" != "v" ]; then
14 # skip other kind of tags beside versions
15 continue
16 fi
17
18 tags[${i}]=${tag}
19 tags_commit[${i}]=`git show-ref ${tag} | cut -d' ' -f1`
20 number_of_tags=$[${number_of_tags}+1]
21
22 i=$[${i}+1]
23 done
24
25 # get the list of commits, test if is a tag and do the diff
26 prev=""
27 git log --pretty=oneline | cut -f1 | \
28 while read commit junk; do
29 # test if it is a tag
30 tag=""
31 i=0
32 while [ "${i}" -lt "${number_of_tags}" ]; do
33 if [ "${commit}" = "${tags_commit[${i}]}" ]; then
34 tag="${tags[${i}]}"
35 break
36 fi
37
38 i=$[${i}+1]
39 done
40
41 if [ -z "${tag}" ]; then
42 continue
43 fi
44
45 if [ ! -z "${prev}" ]; then
46 current=${tag}
47 git shortlog ${current}..${prev} | \
48 (IFS=""
49 while read line; do
50 echo " ${line}"
51 done)
52 echo
53 break
54 fi
55 prev=${tag}
56 done
57 }
58
59 function duilder_final()
60 {
61 PRJ="${1}"
62 VER="${2}"
63 RELEASE_SCRIPT="${3}"
64
65 # Run release script
66 if [ ! -z "${RELEASE_SCRIPT}" -a -x "${RELEASE_SCRIPT}" ]; then
67 echo "Running ${RELEASE_SCRIPT}..."
68 export CHANGELOG=`git_last_changelog`
69 ${RELEASE_SCRIPT}
70 fi
71 }
72
5 73 function duilder_docs() function duilder_docs()
6 74 { {
7 75 PRJ="${1}" PRJ="${1}"
 
... ... function duilder_git()
27 95 PRJ="${1}" PRJ="${1}"
28 96 GIT_DEST="${2}" GIT_DEST="${2}"
29 97 EXPORT_GIT="${3}" EXPORT_GIT="${3}"
30 EXPORT_PATH="${4}"
31 GIT_CHANGELOG="${5}"
32
33 if [ "${EXPORT_GIT}" != "1" ]; then
34 exit 0
35 fi
98 GIT_CHANGELOG="${4}"
99 GIT_PUSH="${5}"
36 100
37 101 if [ ! -x /usr/bin/git ]; then if [ ! -x /usr/bin/git ]; then
38 102 echo "Warning: Git not found!" echo "Warning: Git not found!"
 
... ... function duilder_git()
44 108 exit 0 exit 0
45 109 fi fi
46 110
47 if [ -z "${GIT_DEST}" ]; then
48 GIT_DEST="${EXPORT_PATH}"
111 if [ "${EXPORT_GIT}" = "1" ]; then
112 echo "Generate GIT tree for HTTP transport..."
113 if [ ! -d "${GIT_DEST}/${PRJ}.git" ]; then
114 git clone --bare . "${GIT_DEST}/${PRJ}.git"
115
116 # Activate post-update hook
117 cp "${GIT_DEST}/${PRJ}.git/hooks/post-update.sample" \
118 "${GIT_DEST}/${PRJ}.git/hooks/post-update"
119 chmod a+x "${GIT_DEST}/${PRJ}.git/hooks/post-update"
120
121 # add project name and description
122 echo "${PRJ}" > "${GIT_DEST}/${PRJ}.git/description"
123
124 # allow export by git daemon?
125 #touch "${GIT_DEST}/${PRJ}.git/git-daemon-export-ok
126 else
127 # --force?
128 echo "Running git push -v --all \"${GIT_DEST}/${PRJ}.git\"..."
129 git push -v --all "${GIT_DEST}/${PRJ}.git"
130 echo "Running git push -v --tags \"${GIT_DEST}/${PRJ}.git\"..."
131 git push -v --tags "${GIT_DEST}/${PRJ}.git"
132 fi
133 (cd "${GIT_DEST}/${PRJ}.git" && git update-server-info)
49 134 fi fi
50 135
51 echo "Generate GIT tree for HTTP transport..."
52 if [ ! -d "${GIT_DEST}/${PRJ}.git" ]; then
53 git clone --bare . "${GIT_DEST}/${PRJ}.git"
54
55 # Activate post-update hook
56 cp "${GIT_DEST}/${PRJ}.git/hooks/post-update.sample" \
57 "${GIT_DEST}/${PRJ}.git/hooks/post-update"
58 chmod a+x "${GIT_DEST}/${PRJ}.git/hooks/post-update"
59
60 # add project name and description
61 echo "${PRJ}" > "${GIT_DEST}/${PRJ}.git/description"
62
63 # allow export by git daemon?
64 #touch "${GIT_DEST}/${PRJ}.git/git-daemon-export-ok
65 else
66 # --force?
67 echo "Running git push -v --all \"${GIT_DEST}/${PRJ}.git\"..."
68 git push -v --all "${GIT_DEST}/${PRJ}.git"
69 echo "Running git push -v --tags \"${GIT_DEST}/${PRJ}.git\"..."
70 git push -v --tags "${GIT_DEST}/${PRJ}.git"
136 if [ "${GIT_PUSH}" = "1" ]; then
137 echo "[*] Git push..."
138 git push -v --all
71 139 fi fi
72 (cd "${GIT_DEST}/${PRJ}.git" && git update-server-info)
73
74 140
75 141 if [ "${GIT_CHANGELOG}" = "1" ]; then if [ "${GIT_CHANGELOG}" = "1" ]; then
76 142 echo "[*] Generating Changelog from git..." echo "[*] Generating Changelog from git..."
 
... ... if [ "${1}" = "srpm" ]; then
230 296 exit $? exit $?
231 297 fi fi
232 298
299 if [ "${1}" = "final" ]; then
300 shift
301 duilder_final "$@"
302 exit $?
303 fi
304
233 305 if [ ! -r duilder.conf ]; then if [ ! -r duilder.conf ]; then
234 306 echo "You must build a duilder.conf file!" echo "You must build a duilder.conf file!"
235 307 exit 1 exit 1
 
... ... fi
240 312
241 313 source ${PWD}/duilder.conf source ${PWD}/duilder.conf
242 314
315 # fixes
316 if [ -z "${GIT_DEST}" ]; then
317 GIT_DEST="${EXPORT_PATH}"
318 fi
319
320 # export variables - just in case a script cares
321 export PRJ VER REV EXPORT_PATH EXPORT_GIT GIT_PUSH GIT_DEST SRPMS_DEST LICENSE
322
243 323 if [ -z "${PRJ}" ]; then if [ -z "${PRJ}" ]; then
244 324 echo "ERROR: PRJ= parameter is missing." echo "ERROR: PRJ= parameter is missing."
245 325 exit 1 exit 1
 
... ... if [ -r Makefile.in ]; then
438 518 echo >> Makefile echo >> Makefile
439 519 echo ".PHONY: dist" >> Makefile echo ".PHONY: dist" >> Makefile
440 520 echo "dist: clean" >> Makefile echo "dist: clean" >> Makefile
441 echo " @./duilder git \"\$(PRJ)\" \"${GIT_DEST}\" \"${EXPORT_GIT}\" \"${EXPORT_PATH}\" \"${GIT_CHANGELOG}\"" >> Makefile
521 echo " @./duilder git \"\$(PRJ)\" \"${GIT_DEST}\" \"${EXPORT_GIT}\" \"${GIT_CHANGELOG}\"" \"${GIT_PUSH}\" >> Makefile
442 522 echo " @./duilder tar \"\$(PRJ)\" \"\$(VER)\" \"${EXPORT_PATH}\" \"${EXCLUDE}\"" >> Makefile echo " @./duilder tar \"\$(PRJ)\" \"\$(VER)\" \"${EXPORT_PATH}\" \"${EXCLUDE}\"" >> Makefile
443 523 echo " @./duilder srpm \"\$(PRJ)\" \"\$(VER)\" \"${EXPORT_PATH}\" \"${BUILD_SRPM}\" \"${SRPM_DEST}\" \"${SRPM_POST_RUN}\"" >> Makefile echo " @./duilder srpm \"\$(PRJ)\" \"\$(VER)\" \"${EXPORT_PATH}\" \"${BUILD_SRPM}\" \"${SRPM_DEST}\" \"${SRPM_POST_RUN}\"" >> Makefile
444 524 echo " @./duilder docs \"\$(PRJ)\" \"\$(VER)\" \"${EXPORT_PATH}\"" >> Makefile echo " @./duilder docs \"\$(PRJ)\" \"\$(VER)\" \"${EXPORT_PATH}\"" >> Makefile
525 echo " @./duilder final \"\$(PRJ)\" \"\$(VER)\" \"${RELEASE_SCRIPT}\"" >> Makefile
445 526 echo " @rm -f \"\$(PRJ)-\$(VER).tar.gz\"" >> Makefile echo " @rm -f \"\$(PRJ)-\$(VER).tar.gz\"" >> Makefile
446 527 echo >> Makefile echo >> Makefile
447 528 fi fi
Hints:
Before first commit, do not forget to setup your git environment:
git config --global user.name "your_name_here"
git config --global user.email "your@email_here"

Clone this repository using HTTP(S):
git clone https://rocketgit.com/user/catalinux/Conn

Clone this repository using ssh (do not forget to upload a key first):
git clone ssh://rocketgit@ssh.rocketgit.com/user/catalinux/Conn

Clone this repository using git:
git clone git://git.rocketgit.com/user/catalinux/Conn

You are allowed to anonymously push to this repository.
This means that your pushed commits will automatically be transformed into a merge request:
... clone the repository ...
... make some changes and some commits ...
git push origin main