Closed Bahrom2101 closed 2 years ago
What step are you stuck at?
You need to package your app as an installer with inno setup / nsis.
You need to package your app as an installer with inno setup / nsis.
My steps were:
Did you change the version number of Runner.rc? Since flutter windows cannot automatically update the version number at present, you need to modify it yourself.
Did you change the version number of Runner.rc? Since flutter windows cannot automatically update the version number at present, you need to modify it yourself.
I am doing it that way but no work. Maybe it's from appcast.xml My appcast URL is https://test.cdn.billz.ai/billz/appcast.xml Is this normal?
@Bahrom2101 it works for both MacOS and Windows, we have it working on both. @lijy91 instead of references other tickets it might be good to update the readme.
@Bahrom2101 it works for both MacOS and Windows, we have it working on both. @lijy91 instead of references other tickets it might be good to update the readme.
Can you provide your appcast make and read details?
Sure, here is an example of an app cast.
@Bahrom2101 also keep in mind, for Apple you will need to Notorise your app for it to install without making users go though weird security loops.
<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:sparkle="http://www.andymatuschak.org/xml-namespaces/sparkle">
<channel>
<title>MyApp</title>
<description>Most recent updates to MyApp</description>
<language>en</language>
<item>
<title>Version 1.0.2</title>
<description>
<h1>New update</h1>
<p>Welcome to MyApp 1.0.2!</p>
</description>
<!-- Build number, what it uses to update. -->
<sparkle:version>18</sparkle:version>
<sparkle:shortVersionString>1.0.2</sparkle:shortVersionString>
<pubDate>Sun, 7 Jun 2022 12:00:00 +0000</pubDate>
<enclosure url="https://storage.googleapis.com/MyApp-dev/macos_builds/MyApp_macos_1.0.2+18.zip"
sparkle:edSignature="yeScRLFcBlFsZGns0gMr36yiqXCKqeIkV+CxXeak+t8CSaVuS5dQcHZ5EMERcwI8aMomhBA=="
sparkle:os="macos"
length="28781045"
type="application/octet-stream" />
</item>
<item>
<title>Version 1.0.2</title>
<description>
<h1>New update</h1>
<p>Welcome to MyApp 1.0.2!</p>
</description>
<!-- Build number is broken on Windows -->
<sparkle:version>1.0.2</sparkle:version>
<pubDate>Sun, 7 Jun 2022 12:00:00 +0000</pubDate>
<enclosure url="https://storage.googleapis.com/MyApp-dev/windows_builds/MyApp-1.0.1+15.exe"
sparkle:dsaSignature="MEQCIBVHZCZR6wThDoEXN/xx0AXAiAuNgBi5B4yH/qagELEMCFiMAEzz3C64lIGRrIDDuRvqg=="
sparkle:os="windows"
length="0"
type="application/octet-stream" />
</item>
</channel>
</rss>
@Bahrom2101 you also need to update the runner.rc manually, since flutter doesn't update it.
@lijy91 @ollyde this is my appcast.xml file after second update (I add some changes to the project, then release windows with flutter_distributor command, sign the app after update, and then create appcast file like below) :
<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:sparkle="http://www.andymatuschak.org/xml-namespaces/sparkle">
<channel>
<title>kiosk app update</title>
<description>Most recent updates to kiosk</description>
<language>en</language>
<item>
<title>Version 1.0.2</title>
<pubDate>Wed, 6 June 2024 10:28:00 +0800</pubDate>
<enclosure url="url for exe" sparkle:dsaSignature="MD0CHQCRaSvLRZOaPRQegfbgis9qoY/pazzyAhoGskDBAhxhBTg3bVvOKFqGrUnT9d/0LKk/8b0qR5fUHsLp" sparkle:version="1.0.2+1" sparkle:os="windows" length="0" type="application/octet-stream"/>
</item>
</channel>
</rss>
but when ever I open the app, it checks for updates and it detects that there is a newer version, it starts downloading updates but in the middle, it gives this message:
an error occured in retrieving update information, are you connected to internt? please try again later.
my Runner.rc:
#if defined(FLUTTER_VERSION_MAJOR) && defined(FLUTTER_VERSION_MINOR) && defined(FLUTTER_VERSION_PATCH) && defined(FLUTTER_VERSION_BUILD)
#define VERSION_AS_NUMBER FLUTTER_VERSION_MAJOR,FLUTTER_VERSION_MINOR,FLUTTER_VERSION_PATCH,FLUTTER_VERSION_BUILD
#else
#define VERSION_AS_NUMBER 1,0,2,1
#endif
#if defined(FLUTTER_VERSION)
#define VERSION_AS_STRING FLUTTER_VERSION
#else
#define VERSION_AS_STRING "1.0.2.1"
#endif
version in pubspec.yaml: 1.0.2+1
I dont know what I'm doing wrong! should I run "flutter windows build" after each update??
I have a desktop project mostly for windows users and I want to update it by itself. I am attempting to use this plugin. Please, make the documentation more accessible. I am so confused about what to do. I've created a server that holds my exe and appcast.xml file. I am feeding autoupdater from appcast's URL. But it is not working. What do I have to do ?