summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 962c44de163db55b30e1666f6124f28d9c837dec (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
# Maintainer: abod8639 <https://github.com/abod8639>

pkgname=anodemcu
pkgver=3.0.4
pkgrel=1
pkgdesc="A powerful interactive shell script to manage MCU projects (Arduino, ESP-IDF, PlatformIO)"
arch=('any')
url="https://github.com/abod8639/${pkgname}"
license=('MIT')
depends=('arduino-cli' 'fzf' 'jq' 'neovim')
optdepends=()
source=("https://github.com/abod8639/${pkgname}/archive/refs/tags/v${pkgver}.tar.gz")
sha256sums=('696c01ca33d4e6e8fe12a6d7fda172608e6e58e306e56f5ebe976deeb086d531')

package() {
  cd "${srcdir}/${pkgname}-${pkgver}"
  
  # Define destination directory
  local _dest="${pkgdir}/usr/share/${pkgname}"
  install -d "${_dest}"
  
  # Install library files
  cp -r lib/ "${_dest}/"
  
  # Install the main script
  install -m755 "anodemcu" "${_dest}/"
  
  # Create a symlink in /usr/bin for global access
  install -d "${pkgdir}/usr/bin"
  ln -s "/usr/share/${pkgname}/anodemcu" "${pkgdir}/usr/bin/${pkgname}"
  
  # Install documentation and license
  install -Dm644 "README.md" "${pkgdir}/usr/share/doc/${pkgname}/README.md"
  install -Dm644 "LICENSE" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}