Files
Musify/update.sh
2024-04-29 16:39:43 +04:00

12 lines
310 B
Bash

#!/bin/bash
# Read the version from pubspec.yaml
version=$(grep version pubspec.yaml | awk -F'[ +]' '{print $2}' | tr -d "'")
# Define the variable name and file name
variable="appVersion"
filename="lib/API/version.dart"
# Write the version to the Dart file
echo "const $variable = '$version';" > $filename