Skip to content

Commit

Permalink
core24 upgrade
Browse files Browse the repository at this point in the history
  • Loading branch information
kz6fittycent committed Oct 23, 2024
1 parent 6866623 commit bb222b4
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 8 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/test-snap-can-build.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: 🧪 Test snap can be built on x86_64
name: 🧪 Snap Builds

on:
push:
Expand Down
12 changes: 12 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,18 @@ webpage for a list of **[All Supported Installations](https://fpm.fortran-lang.o

The easiest installation routes are shown below.

### [Snap](https://snapcraft.io/fortran-fpm)

[![fortran-fpm](https://snapcraft.io/fortran-fpm/badge.svg)](https://snapcraft.io/fortran-fpm)

[![🧪 Snap Builds](https://github.com/kz6fittycent/fpm/actions/workflows/test-snap-can-build.yml/badge.svg?branch=main)](https://github.com/kz6fittycent/fpm/actions/workflows/test-snap-can-build.yml)

**Note:** Linux only

```
sudo snap install fortran-fpm
```

### [Binary](https://github.com/fortran-lang/fpm/releases)

Binaries for the latest stable release are available [to download](https://github.com/fortran-lang/fpm/releases/latest) for Windows, MacOS, and Linux.
Expand Down
Binary file added snap/local/fpm.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
20 changes: 13 additions & 7 deletions snap/snapcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,14 +26,20 @@ description: |
Website: https://fpm.fortran-lang.org/
license: MIT
source-code: https://github.com/fortran-lang/fpm
issues: https://github.com/kz6fittycent/fpm/issues
contact: https://github.com/kz6fittycent/fpm
icon: snap/local/fpm.png

base: core20
base: core24
grade: stable
confinement: strict
compression: lzo

architectures:
- build-on: amd64
platforms:
amd64:
build-on: [amd64]
build-for: [amd64]

apps:
fortran-fpm:
Expand All @@ -56,12 +62,12 @@ parts:
LATEST=$(curl -s https://api.github.com/repos/fortran-lang/fpm/releases/latest | grep '"tag_name":' | cut -d ":" -f2 | sed -E 's/.*"([^"]+)".*/\1/' | sed -E 's/^v//')
################################
mkdir -p $SNAPCRAFT_PART_INSTALL/usr/bin/
cd $SNAPCRAFT_PART_INSTALL/usr/bin/
mkdir -p $CRAFT_PART_INSTALL/usr/bin/
cd $CRAFT_PART_INSTALL/usr/bin/
wget -O fpm "https://github.com/fortran-lang/fpm/releases/download/v${LATEST}/fpm-${LATEST}-linux-x86_64"
chmod a+x fpm
override-pull: |
snapcraftctl pull
snapcraftctl set-version "$(curl -s https://api.github.com/repos/fortran-lang/fpm/releases/latest | grep '"tag_name":' | cut -d ":" -f2 | sed -E 's/.*"([^"]+)".*/\1/' | sed -E 's/^v//')"
craftctl default
craftctl set version="$(curl -s https://api.github.com/repos/fortran-lang/fpm/releases/latest | grep '"tag_name":' | cut -d ":" -f2 | sed -E 's/.*"([^"]+)".*/\1/' | sed -E 's/^v//')"

0 comments on commit bb222b4

Please sign in to comment.