Skip to content

Commit fbd2b1d

Browse files
committed
Update dependencies and Makefile menu
1 parent 3283913 commit fbd2b1d

5 files changed

Lines changed: 25 additions & 39 deletions

File tree

Makefile

Lines changed: 21 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -101,23 +101,10 @@ help:
101101
@echo "$(PROJECT) Makefile."
102102
@echo "The following commands are available:"
103103
@echo ""
104-
@echo " make buildall : Build and test everything from scratch"
105-
@echo " make bz2 : Package the library in a compressed bz2 archive"
106-
@echo " make clean : Delete the vendor and target directories"
107-
@echo " make codefix : Fix code style violations"
108-
@echo " make deb : Build a DEB package for Debian-like Linux distributions"
109-
@echo " make deps : Download all dependencies"
110-
@echo " make doc : Generate source code documentation"
111-
@echo " make lint : Test source code for coding standard violations"
112-
@echo " make qa : Run all tests and reports"
113-
@echo " make report : Generate various reports"
114-
@echo " make rpm : Build an RPM package for RedHat-like Linux distributions"
115-
@echo " make server : Start the development server"
116-
@echo " make test : Run unit tests"
117-
@echo " make versionup: Increase the version patch number"
104+
@awk '/^## /{desc=substr($$0,4)} /^\.PHONY:/{if(NF>1) {target=$$2; if(desc) printf " make %-15s: %s\n",target,desc; desc=""}}' Makefile
118105
@echo ""
119-
@echo "To test and build everything from scratch:"
120-
@echo "make buildall"
106+
@echo "To test and build everything from scratch, use the shortcut:"
107+
@echo " make x"
121108
@echo ""
122109

123110
# alias for help target
@@ -128,28 +115,28 @@ all: help
128115
.PHONY: x
129116
x: buildall
130117

131-
# Full build and test sequence
118+
## Full build and test sequence
132119
.PHONY: buildall
133120
buildall: deps codefix qa bz2 rpm deb
134121

135-
# Package the library in a compressed bz2 archive
122+
## Package the library in a compressed bz2 archive
136123
.PHONY: bz2
137124
bz2:
138125
rm -rf $(PATHBZ2PKG)
139126
make install DESTDIR=$(PATHBZ2PKG)
140127
tar -jcvf $(PATHBZ2PKG)/$(PKGNAME)-$(VERSION)-$(RELEASE).tbz2 -C $(PATHBZ2PKG) $(DATADIR)
141128

142-
# Delete the vendor and target directories
129+
## Delete the vendor and target directories
143130
.PHONY: clean
144131
clean:
145132
rm -rf ./vendor $(TARGETDIR)
146133

147-
# Fix code style violations
134+
## Fix code style violations
148135
.PHONY: codefix
149136
codefix:
150137
./vendor/bin/phpcbf --ignore="\./vendor/" --standard=psr12 src test
151138

152-
# Build a DEB package for Debian-like Linux distributions
139+
## Build a DEB package for Debian-like Linux distributions
153140
.PHONY: deb
154141
deb:
155142
rm -rf $(PATHDEBPKG)
@@ -174,28 +161,28 @@ endif
174161
echo "new-package-should-close-itp-bug" > $(PATHDEBPKG)/$(PKGNAME)-$(VERSION)/debian/$(PKGNAME).lintian-overrides
175162
cd $(PATHDEBPKG)/$(PKGNAME)-$(VERSION) && debuild -us -uc
176163

177-
# Clean all artifacts and download all dependencies
164+
## Clean all artifacts and download all dependencies
178165
.PHONY: deps
179166
deps: ensuretarget
180167
rm -rf ./vendor/*
181168
($(COMPOSER) install -vvv --no-interaction)
182169
curl --silent --show-error --fail --location --output ./vendor/phpstan.phar https://github.com/phpstan/phpstan/releases/download/${PHPSTANVER}/phpstan.phar \
183170
&& chmod +x ./vendor/phpstan.phar
184171

185-
# Generate source code documentation
172+
## Generate source code documentation
186173
.PHONY: doc
187174
doc: ensuretarget
188175
rm -rf $(TARGETDIR)/doc
189176
$(PHPDOC) -d ./src -t $(TARGETDIR)/doc/
190177

191-
# Create missing target directories for test and build artifacts
178+
## Create missing target directories for test and build artifacts
192179
.PHONY: ensuretarget
193180
ensuretarget:
194181
mkdir -p $(TARGETDIR)/test
195182
mkdir -p $(TARGETDIR)/report
196183
mkdir -p $(TARGETDIR)/doc
197184

198-
# Install this application
185+
## Install this application
199186
.PHONY: install
200187
install: uninstall
201188
mkdir -p $(PATHINSTBIN)
@@ -217,7 +204,7 @@ ifneq ($(strip $(CONFIGPATH)),)
217204
find $(PATHINSTCFG) -type f -exec chmod 644 {} \;
218205
endif
219206

220-
# Test source code for coding standard violations
207+
## Test source code for coding standard violations
221208
.PHONY: lint
222209
lint:
223210
./vendor/bin/phpcs --standard=phpcs.xml
@@ -226,17 +213,17 @@ lint:
226213
./vendor/bin/phpmd test text unusedcode,naming,design --exclude */vendor/*
227214
php -r 'exit((int)version_compare(PHP_MAJOR_VERSION, "7", ">"));' || ./vendor/phpstan.phar analyse
228215

229-
# Run all tests and reports
216+
## Run all tests and reports
230217
.PHONY: qa
231218
qa: ensuretarget lint test report
232219

233-
# Generate various reports
220+
## Generate various reports
234221
.PHONY: report
235222
report: ensuretarget
236223
./vendor/bin/pdepend --jdepend-xml=$(TARGETDIR)/report/dependencies.xml --summary-xml=$(TARGETDIR)/report/metrics.xml --jdepend-chart=$(TARGETDIR)/report/dependecies.svg --overview-pyramid=$(TARGETDIR)/report/overview-pyramid.svg --ignore=vendor ./src
237224
#./vendor/bartlett/php-compatinfo/bin/phpcompatinfo --no-ansi analyser:run src/ > $(TARGETDIR)/report/phpcompatinfo.txt
238225

239-
# Build the RPM package for RedHat-like Linux distributions
226+
## Build the RPM package for RedHat-like Linux distributions
240227
.PHONY: rpm
241228
rpm:
242229
rm -rf $(PATHRPMPKG)
@@ -254,34 +241,33 @@ rpm:
254241
--define "_configpath /$(CONFIGPATH)" \
255242
-bb resources/rpm/rpm.spec
256243

257-
# Start the development server
244+
## Start the development server
258245
.PHONY: server
259246
server:
260247
$(PHP) -t example -S localhost:$(PORT)
261248

262-
# Tag this GIT version
249+
## Tag this GIT version
263250
.PHONY: tag
264251
tag:
265252
git checkout main && \
266253
git tag -a ${VERSION} -m "Release ${VERSION}" && \
267254
git push origin --tags && \
268255
git pull
269256

270-
# Run unit tests
257+
## Run unit tests
271258
.PHONY: test
272259
test:
273260
cp phpunit.xml.dist phpunit.xml
274261
#./vendor/bin/phpunit --migrate-configuration || true
275262
XDEBUG_MODE=coverage ./vendor/bin/phpunit --stderr test
276263

277-
# Remove all installed files
264+
## Remove all installed files
278265
.PHONY: uninstall
279266
uninstall:
280267
rm -rf $(PATHINSTBIN)
281268
rm -rf $(PATHINSTDOC)
282269

283-
# Increase the version patch number
270+
## Increase the version patch number
284271
.PHONY: versionup
285272
versionup:
286273
echo ${VERSION} | gawk -F. '{printf("%d.%d.%d\n",$$1,$$2,(($$3+1)));}' > VERSION
287-

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
2.0.45
1+
2.0.46

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
"require-dev": {
3333
"pdepend/pdepend": "2.16.2",
3434
"phpmd/phpmd": "2.15.0",
35-
"phpunit/phpunit": "13.0.5 || 12.5.14 || 11.5.55 || 10.5.63",
35+
"phpunit/phpunit": "13.1.1 || 12.5.17 || 11.5.55 || 10.5.63",
3636
"squizlabs/php_codesniffer": "4.0.1",
3737
"phpcompatibility/php-compatibility": "^10.0.0@dev"
3838
},

resources/debian/control

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,6 @@ Vcs-Git: https://github.com/~#VENDOR#~/~#PROJECT#~.git
1010
Package: ~#PKGNAME#~
1111
Provides: php-~#PROJECT#~
1212
Architecture: all
13-
Depends: php (>= 8.1.0), php-mbstring, php-tecnickcom-tc-lib-unicode-data (<< 3.0.0), php-tecnickcom-tc-lib-unicode-data (>= 2.0.44), ${misc:Depends}
13+
Depends: php (>= 8.1.0), php-mbstring, php-tecnickcom-tc-lib-unicode-data (<< 3.0.0), php-tecnickcom-tc-lib-unicode-data (>= 2.0.45), ${misc:Depends}
1414
Description: PHP Unicode methods.
1515
PHP library containing Unicode methods.

resources/rpm/rpm.spec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ BuildArch: noarch
1818

1919
Requires: php(language) >= 8.1.0
2020
Requires: php-composer(%{c_vendor}/tc-lib-unicode-data) < 3.0.0
21-
Requires: php-composer(%{c_vendor}/tc-lib-unicode-data) >= 2.0.44
21+
Requires: php-composer(%{c_vendor}/tc-lib-unicode-data) >= 2.0.45
2222
Requires: php-pcre
2323
Requires: php-mbstring
2424

0 commit comments

Comments
 (0)