Switch to new download format, update dependencies and source.sh script

This commit is contained in:
2025-12-06 17:41:14 +02:00
parent f3fda69750
commit ab0e2860b4
2 changed files with 17 additions and 9 deletions
+13 -2
View File
@@ -1,9 +1,20 @@
name: micro
description: A modern and intuitive terminal-based text editor
version: 2.0.14
revision: 4
revision: 5
url: https://micro-editor.github.io/
license: MIT
architecture: any
make_depends: ["golang"]
type: source
optional_depends:
- wl-clipboard
- xclip
make_depends:
- git
- golang
downloads:
- url: https://github.com/zyedidia/micro.git
type: git
clone_to: ${BPM_SOURCE}
git_branch: v${BPM_PKG_VERSION}
checksum: 04c577049ca898f097cd6a2dae69af0b4d4493e1
+4 -7
View File
@@ -2,23 +2,20 @@
# BPM Expects the source code to be extracted into the automatically created 'source' directory which can be accessed using $BPM_SOURCE
# BPM Expects the output files to be present in the automatically created 'output' directory which can be accessed using $BPM_OUTPUT
DOWNLOAD="https://github.com/zyedidia/micro/archive/refs/tags/v${BPM_PKG_VERSION}.tar.gz"
FILENAME="${DOWNLOAD##*/}"
# The prepare function is executed in the root of the temp directory
# This function is used for downloading files and putting them into the correct location
prepare() {
wget "$DOWNLOAD"
tar -xvf "$FILENAME" --strip-components=1 -C "$BPM_SOURCE"
cd "$BPM_SOURCE"
# Modify Go build flags
sed -i 's/-trimpath/-buildmode=pie -trimpath/g;s/GS)/GS) -linkmode=external -extldflags \\"$(LDFLAGS)\\"/g' Makefile
# Download go modules
GOFLAGS="-modcacherw" go mod download
}
# The build function is executed in the source directory
# This function is used to compile the source code
build() {
make VERSION="$BPM_PKG_VERSION"
make
}
# The check function is executed in the source directory