Compare commits
	
		
			25 Commits
		
	
	
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| 13c25eb2ea | |||
| c48181bf1e | |||
| 8bb619c676 | |||
| 82af05c4b0 | |||
| 3e9d6db60a | |||
| 07d3f19d07 | |||
| c912adb647 | |||
| eed3f85bc2 | |||
| 3ae4c3548e | |||
| 
						 | 
					fc7f7c3c49 | ||
| 
						 | 
					f0e4ed1829 | ||
| 
						 | 
					6bef8344cb | ||
| 60561cf341 | |||
| f06fe26a01 | |||
| 
						 | 
					8d1a3a4eb7 | ||
| 
						 | 
					d249c5798f | ||
| 
						 | 
					21915e403d | ||
| 
						 | 
					c0d13f7109 | ||
| 
						 | 
					605dcc7317 | ||
| 
						 | 
					8b0ce9826f | ||
| 
						 | 
					90043d5bc7 | ||
| 
						 | 
					0b3ef51543 | ||
| a49d3283e9 | |||
| cef3feefb9 | |||
| 
						 | 
					c6c276c67d | 
							
								
								
									
										22
									
								
								.drone.yml
									
									
									
									
									
								
							
							
						
						
									
										22
									
								
								.drone.yml
									
									
									
									
									
								
							@@ -1,22 +0,0 @@
 | 
				
			|||||||
pipeline:
 | 
					 | 
				
			||||||
  build:
 | 
					 | 
				
			||||||
    image: debian
 | 
					 | 
				
			||||||
    pull: true
 | 
					 | 
				
			||||||
    commands:
 | 
					 | 
				
			||||||
      - apt update && apt install -y make wget
 | 
					 | 
				
			||||||
      - make
 | 
					 | 
				
			||||||
      - ls -la
 | 
					 | 
				
			||||||
      - make install
 | 
					 | 
				
			||||||
      - ls -la
 | 
					 | 
				
			||||||
    when:
 | 
					 | 
				
			||||||
      event: [push, tag]
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  package:
 | 
					 | 
				
			||||||
    image: debian
 | 
					 | 
				
			||||||
    pull: true
 | 
					 | 
				
			||||||
    commands:
 | 
					 | 
				
			||||||
      - apt update && apt install -y build-essential fakeroot devscripts wget
 | 
					 | 
				
			||||||
      - make package
 | 
					 | 
				
			||||||
      - ls -la
 | 
					 | 
				
			||||||
    when:
 | 
					 | 
				
			||||||
      event: tag
 | 
					 | 
				
			||||||
							
								
								
									
										2
									
								
								.gitignore
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										2
									
								
								.gitignore
									
									
									
									
										vendored
									
									
								
							@@ -1,5 +1,5 @@
 | 
				
			|||||||
*.exe
 | 
					*.exe
 | 
				
			||||||
/data/
 | 
					/build/
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# ignore the debian stuff
 | 
					# ignore the debian stuff
 | 
				
			||||||
debhelper-build-stamp
 | 
					debhelper-build-stamp
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										33
									
								
								.woodpecker.yml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										33
									
								
								.woodpecker.yml
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,33 @@
 | 
				
			|||||||
 | 
					pipeline:
 | 
				
			||||||
 | 
					  build_deb:
 | 
				
			||||||
 | 
					    image: gitea.mdg-hamburg.de/ci-tools/deb-buildpackage:latest
 | 
				
			||||||
 | 
					    pull: true
 | 
				
			||||||
 | 
					    commands:
 | 
				
			||||||
 | 
					      - make package
 | 
				
			||||||
 | 
					      - ls ..
 | 
				
			||||||
 | 
					      - dpkg -c ../*.deb
 | 
				
			||||||
 | 
					    when:
 | 
				
			||||||
 | 
					      event: [push, tag]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  publish:
 | 
				
			||||||
 | 
					    image: docker.io/plugins/sftp:linux-amd64
 | 
				
			||||||
 | 
					    pull: true
 | 
				
			||||||
 | 
					    settings:
 | 
				
			||||||
 | 
					      host:
 | 
				
			||||||
 | 
					        from_secret: deb_repo_ssh_host
 | 
				
			||||||
 | 
					      port:
 | 
				
			||||||
 | 
					        from_secret: deb_repo_ssh_port
 | 
				
			||||||
 | 
					      username:
 | 
				
			||||||
 | 
					        from_secret: deb_repo_ssh_username
 | 
				
			||||||
 | 
					      password:
 | 
				
			||||||
 | 
					        from_secret: deb_repo_ssh_password
 | 
				
			||||||
 | 
					      files:
 | 
				
			||||||
 | 
					        - ../*.deb
 | 
				
			||||||
 | 
					        - ../*.dsc
 | 
				
			||||||
 | 
					        - ../*.git
 | 
				
			||||||
 | 
					        - ../*.changes
 | 
				
			||||||
 | 
					      destination_path: /var/www/repository/debian/incoming
 | 
				
			||||||
 | 
					    when:
 | 
				
			||||||
 | 
					      event: [tag]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					branches: master
 | 
				
			||||||
							
								
								
									
										2
									
								
								LICENSE
									
									
									
									
									
								
							
							
						
						
									
										2
									
								
								LICENSE
									
									
									
									
									
								
							@@ -1,6 +1,6 @@
 | 
				
			|||||||
MIT License
 | 
					MIT License
 | 
				
			||||||
 | 
					
 | 
				
			||||||
Copyright (c) 2021 Kevin Dorner
 | 
					Copyright (c) 2022 Kevin Dorner
 | 
				
			||||||
 | 
					
 | 
				
			||||||
Permission is hereby granted, free of charge, to any person obtaining a copy
 | 
					Permission is hereby granted, free of charge, to any person obtaining a copy
 | 
				
			||||||
of this software and associated documentation files (the "Software"), to deal
 | 
					of this software and associated documentation files (the "Software"), to deal
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										74
									
								
								Makefile
									
									
									
									
									
								
							
							
						
						
									
										74
									
								
								Makefile
									
									
									
									
									
								
							@@ -1,48 +1,45 @@
 | 
				
			|||||||
PKGNAME := mdg-test
 | 
					PKG_NAME := mdg-test
 | 
				
			||||||
UPSTREAM_VERSION := 3.9.2
 | 
					PKG_VERSION := 3.9.2
 | 
				
			||||||
PKG_SUB_RELEASE := 1.0
 | 
					PKG_OPSI_RELEASE := 1.0
 | 
				
			||||||
 | 
					PKG_DEB_RELEASE := 1
 | 
				
			||||||
 | 
					
 | 
				
			||||||
SOURCE := https://www.python.org/ftp/python/$(UPSTREAM_VERSION)/python-$(UPSTREAM_VERSION)-amd64.exe
 | 
					# sources and checksums can be found on https://www.python.org/downloads/windows/
 | 
				
			||||||
 | 
					SOURCE_FILENAME := python-$(PKG_VERSION)-amd64.exe
 | 
				
			||||||
 | 
					SOURCE := https://www.python.org/ftp/python/$(PKG_VERSION)/$(SOURCE_FILENAME)
 | 
				
			||||||
CHECKSUM := efb20aa1b648a2baddd949c142d6eb06
 | 
					CHECKSUM := efb20aa1b648a2baddd949c142d6eb06
 | 
				
			||||||
## Download Link and Checksums can be found on https://www.python.org/downloads/windows/
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
#Automatically set variables
 | 
					default: fetch-sources patch-fields
 | 
				
			||||||
PKG_FULL_VERSION := $(UPSTREAM_VERSION)-$(PKG_SUB_RELEASE)
 | 
					 | 
				
			||||||
DEB_CHANGELOG_VERSION := $(shell dpkg-parsechangelog -S Version | sed -rne 's|((-*[^-]+)+)(-[^-]+)|\1|p')
 | 
					 | 
				
			||||||
DEB_ORIG_FILE := $(PKGNAME)_$(PKG_FULL_VERSION).orig.tar.gz
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
default: download
 | 
					BUILDDIR := build
 | 
				
			||||||
 | 
					$(BUILDDIR):
 | 
				
			||||||
 | 
						mkdir -p $(BUILDDIR)/data
 | 
				
			||||||
 | 
					
 | 
				
			||||||
all: | clean install
 | 
					fetch-sources: $(BUILDDIR)
 | 
				
			||||||
 | 
						curl -o $(BUILDDIR)/data/$(SOURCE_FILENAME) $(SOURCE)
 | 
				
			||||||
 | 
						echo "$(CHECKSUM) $(BUILDDIR)/data/$(SOURCE_FILENAME)" | md5sum -c
 | 
				
			||||||
 | 
					
 | 
				
			||||||
download: setversion
 | 
					patch-fields: $(BUILDDIR)
 | 
				
			||||||
	[ -d "data" ] || mkdir data
 | 
						sed -e "s|@PKG_VERSION@|$(PKG_VERSION)|" \
 | 
				
			||||||
	wget -nc -P data $(SOURCE)
 | 
						-e "s|@PKG_OPSI_RELEASE@|$(PKG_OPSI_RELEASE)|" \
 | 
				
			||||||
	echo "$(CHECKSUM) data/python-$(UPSTREAM_VERSION)-amd64.exe" | md5sum -c && \
 | 
						control.in > $(BUILDDIR)/control
 | 
				
			||||||
	echo "SUCCESS: Checksums match" || \
 | 
					 | 
				
			||||||
	{ ec=$$?; echo "ERROR: Checksum mismatch" >&2; rm -rf data >&2; exit $$ec; }
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
data: download
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
install: data
 | 
					 | 
				
			||||||
	install -Dm644 control -t $(DESTDIR)/srv/deploy/install/$(PKGNAME)
 | 
					 | 
				
			||||||
	install -Dm644 *.ins -t $(DESTDIR)/srv/deploy/install/$(PKGNAME)
 | 
					 | 
				
			||||||
	install -Dm644 logo.png -t $(DESTDIR)/srv/deploy/install/$(PKGNAME)
 | 
					 | 
				
			||||||
	install -Dm644 data/* -t $(DESTDIR)/srv/deploy/install/$(PKGNAME)/data
 | 
					 | 
				
			||||||
	
 | 
					 | 
				
			||||||
uninstall:
 | 
					 | 
				
			||||||
	rm -rf $(DESTDIR)/srv/deploy/install/$(PKGNAME)
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
clean:
 | 
					clean:
 | 
				
			||||||
	rm -rf data
 | 
						rm -rf $(BUILDDIR)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
setversion:
 | 
					install: $(BUILDDIR)
 | 
				
			||||||
	@echo "INFO: Writing version $(PKG_FULL_VERSION) to control file"
 | 
						install -Dm644 $(BUILDDIR)/control -t $(DESTDIR)/srv/deploy/install/$(PKG_NAME)
 | 
				
			||||||
	sed -e "s/^version: [0-9]\{1,3\}\.[0-9]\{1,3\}\.[0-9]\{1,3\}$$/version: $(UPSTREAM_VERSION)/" \
 | 
						install -Dm644 $(BUILDDIR)/data/* -t $(DESTDIR)/srv/deploy/install/$(PKG_NAME)/data
 | 
				
			||||||
	-e "s/^packageVersion: [0-9]\{1,3\}\.[0-9]\{1,3\}$$/packageVersion: $(PKG_SUB_RELEASE)/" \
 | 
						install -Dm644 *.ins -t $(DESTDIR)/srv/deploy/install/$(PKG_NAME)
 | 
				
			||||||
	-i control
 | 
						install -Dm644 logo.png -t $(DESTDIR)/srv/deploy/install/$(PKG_NAME)
 | 
				
			||||||
	
 | 
						
 | 
				
			||||||
check-before-package:
 | 
					uninstall:
 | 
				
			||||||
 | 
						rm -rf $(DESTDIR)/srv/deploy/install/$(PKG_NAME)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					package:
 | 
				
			||||||
 | 
						dpkg-buildpackage --unsigned-source --unsigned-changes --no-check-builddeps
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# DEB_CHANGELOG_VERSION := $(shell dpkg-parsechangelog -S Version | sed -rne 's|((-*[^-]+)+)(-[^-]+)|\1|p')
 | 
				
			||||||
 | 
					package-check-changelog:
 | 
				
			||||||
	@if [ "$(DEB_CHANGELOG_VERSION)" != "$(PKG_FULL_VERSION)" ]; then \
 | 
						@if [ "$(DEB_CHANGELOG_VERSION)" != "$(PKG_FULL_VERSION)" ]; then \
 | 
				
			||||||
		echo "Mismatch between debian changelog file and Makefile version"; \
 | 
							echo "Mismatch between debian changelog file and Makefile version"; \
 | 
				
			||||||
		echo "Debian changelog version: $(DEB_CHANGELOG_VERSION)"; \
 | 
							echo "Debian changelog version: $(DEB_CHANGELOG_VERSION)"; \
 | 
				
			||||||
@@ -50,10 +47,5 @@ check-before-package:
 | 
				
			|||||||
		exit 1; \
 | 
							exit 1; \
 | 
				
			||||||
	fi
 | 
						fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
package: check-before-package
 | 
					 | 
				
			||||||
	tar cavzf ../mdg-test_3.9.2-1.0.orig.tar.gz --exclude="debian" --exclude="**/.*" .
 | 
					 | 
				
			||||||
	debuild -us -uc --diff-ignore="\.\S+" -I
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
.PHONY: default all download install uninstall clean setversion check-berfore-package package
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					.PHONY: default fetch-sources patch-fields clean install uninstall package package-check-changelog
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1,3 +1,4 @@
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
# mdg-python
 | 
					# mdg-python
 | 
				
			||||||
A better Python for Windows OPSI package aimed to work with IServ
 | 
					A better Python for Windows OPSI package aimed to work with IServ
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -4,8 +4,8 @@ id: mdg-python
 | 
				
			|||||||
name: MDG Python
 | 
					name: MDG Python
 | 
				
			||||||
description: Python für Microsoft Windows mit pip-Unterstützung
 | 
					description: Python für Microsoft Windows mit pip-Unterstützung
 | 
				
			||||||
advice: Vereinfachtes Paket mit neuer Python-Version und funktionsfähiger pip-Unterstützung
 | 
					advice: Vereinfachtes Paket mit neuer Python-Version und funktionsfähiger pip-Unterstützung
 | 
				
			||||||
version: 3.9.2
 | 
					version: @PKG_VERSION@
 | 
				
			||||||
packageVersion: 1.0
 | 
					packageVersion: @PKG_OPSI_RELEASE@
 | 
				
			||||||
setupScript: install.ins
 | 
					setupScript: install.ins
 | 
				
			||||||
uninstallScript: remove.ins
 | 
					uninstallScript: remove.ins
 | 
				
			||||||
 | 
					
 | 
				
			||||||
							
								
								
									
										1
									
								
								debian/source/format
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								debian/source/format
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1 @@
 | 
				
			|||||||
 | 
					3.0 (git)
 | 
				
			||||||
@@ -53,6 +53,7 @@ endif
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
[Files_Cleanup]
 | 
					[Files_Cleanup]
 | 
				
			||||||
; This ensures all data has been removed
 | 
					; This ensures all data has been removed
 | 
				
			||||||
 | 
					; Leave previous versions for future removal
 | 
				
			||||||
delete -sf "%ProgramFiles64Dir%\python39\"
 | 
					delete -sf "%ProgramFiles64Dir%\python39\"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
[WinBatch_Setup]
 | 
					[WinBatch_Setup]
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user