Skip to content
This repository has been archived by the owner on Jun 30, 2021. It is now read-only.

Commit

Permalink
Merge pull request #15 from manuelsteiner/master
Browse files Browse the repository at this point in the history
Implement xdelta3 and fix lua env replacement
  • Loading branch information
gares authored Jun 17, 2020
2 parents 0e5981f + 248e53b commit 388f3eb
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
steps:
- uses: actions/checkout@v2
- name: install dependencies
run: sudo apt-get install txt2man pkg-config libglib2.0-dev libgtk-3-dev libnotify-dev libgee-0.8-dev lua5.1 moreutils xdelta
run: sudo apt-get install txt2man pkg-config libglib2.0-dev libgtk-3-dev libnotify-dev libgee-0.8-dev lua5.1 moreutils xdelta3
- name: build
run: make
- name: test
Expand Down
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ H=@

PREFIX=usr/local
SED=sed
XDELTA=xdelta
XDELTA=xdelta3
SSH=ssh
LUAV=5.1
LUA=lua$(LUAV)
Expand Down Expand Up @@ -150,7 +150,7 @@ define install-replacing
$(SED) 's?@XDELTA@?$(XDELTA)?' |\
$(SED) 's?@SSH@?$(SSH)?' |\
$(SED) 's?@SMDVERSION@?$(VERSION)?' |\
$(SED) 's?#! /usr/bin/env lua.*?#! /usr/bin/env $(LUA)?' |\
$(SED) 's?#!/usr/bin/env lua.*?#!/usr/bin/env $(LUA)?' |\
cat > $(DESTDIR)/$(PREFIX)/$(2)/$(1)
if [ $(2) = "bin" ]; then chmod a+rx $(DESTDIR)/$(PREFIX)/$(2)/$(1); fi
endef
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -453,7 +453,7 @@ supported by templates defined at the end of `Makefile`, for example you may
want to run `make osx/text/all && make osx/text/install` to properly build and
install text mode only syncmaildir utilities on an MacOSX platform.

Runtime dependencies are: `ssh`, `xdelta`, `lua5.1` and `bash`.
Runtime dependencies are: `ssh`, `xdelta3`, `lua5.1` and `bash`.

Design
======
Expand Down
4 changes: 2 additions & 2 deletions smd-client
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#! /usr/bin/env lua5.1
#!/usr/bin/env lua5.1
--
-- Released under the terms of GPLv3 or at your option any later version.
-- No warranties.
Expand Down Expand Up @@ -762,7 +762,7 @@ function main()

local rc
if not dry_run() and apply_xdelta then
rc = os.execute(XDELTA..' patch '..xdelta..' '..dbfile..' '..newdb)
rc = os.execute(XDELTA..' -d -s '..dbfile..' '..xdelta..' '..newdb)
else
rc = 0 -- the xdelta transmitted with --dry-run is dummy
end
Expand Down
4 changes: 2 additions & 2 deletions smd-server
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#! /usr/bin/env lua5.1
#!/usr/bin/env lua5.1
--
-- Released under the terms of GPLv3 or at your option any later version.
-- No warranties.
Expand Down Expand Up @@ -162,7 +162,7 @@ function main()
local rc
if not dry_run() then
rc = os.execute(
XDELTA..' delta '..dbfile..' '..newdb..' '..xdelta)
XDELTA..' -e -s '..dbfile..' '..newdb..' '..xdelta)
else
local f = io.open(xdelta,'w')
f:close()
Expand Down
2 changes: 1 addition & 1 deletion syncmaildir.lua
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ end
-- set xdelta executable name
XDELTA = '@XDELTA@'
if string.sub(XDELTA,1,1) == '@' then
XDELTA = 'xdelta'
XDELTA = 'xdelta3'
end

-- set smd version
Expand Down

0 comments on commit 388f3eb

Please sign in to comment.