Skip to content

Commit

Permalink
reactivate build script
Browse files Browse the repository at this point in the history
  • Loading branch information
wiegell committed Nov 23, 2022
1 parent 704f747 commit e93d1a1
Show file tree
Hide file tree
Showing 2 changed files with 72 additions and 72 deletions.
66 changes: 33 additions & 33 deletions AstroWall/Info.plist
Original file line number Diff line number Diff line change
@@ -1,36 +1,36 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleName</key>
<string>Astro Wall</string>
<key>CFBundleIdentifier</key>
<string>com.astro.wall.Astro-Wall</string>
<key>CFBundleShortVersionString</key>
<string>0.1.3</string>
<key>CFBundleVersion</key>
<string>0.1.3-alpha-1-g2490012</string>
<key>LSMinimumSystemVersion</key>
<string>11</string>
<key>CFBundleDevelopmentRegion</key>
<string>en</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>NSHumanReadableCopyright</key>
<string>${AuthorCopyright:HtmlEncode}</string>
<key>NSPrincipalClass</key>
<string>NSApplication</string>
<key>NSMainStoryboardFile</key>
<string>Main</string>
<key>XSAppIconAssets</key>
<string>Assets.xcassets/AppIcon.appiconset</string>
<key>LSUIElement</key>
<true/>
<key>BUNDLE VERSION COMMENT</key>
<string>Bundle version is updated &quot;after&quot; a commit has been made (because it needs to reflect the commit hash). Therefore its always &quot;one commit behind&quot; in version history, but is updated to actual version on build.</string>
</dict>
</plist>
<dict>
<key>CFBundleName</key>
<string>Astro Wall</string>
<key>CFBundleIdentifier</key>
<string>com.astro.wall.Astro-Wall</string>
<key>CFBundleShortVersionString</key>
<string>0.1.5</string>
<key>CFBundleVersion</key>
<string>0.1.5-alpha-1-g704f747</string>
<key>LSMinimumSystemVersion</key>
<string>11</string>
<key>CFBundleDevelopmentRegion</key>
<string>en</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>NSHumanReadableCopyright</key>
<string>${AuthorCopyright:HtmlEncode}</string>
<key>NSPrincipalClass</key>
<string>NSApplication</string>
<key>NSMainStoryboardFile</key>
<string>Main</string>
<key>XSAppIconAssets</key>
<string>Assets.xcassets/AppIcon.appiconset</string>
<key>LSUIElement</key>
<true/>
<key>BUNDLE VERSION COMMENT</key>
<string>Bundle version is updated "after" a commit has been made (because it needs to reflect the commit hash). Therefore its always "one commit behind" in version history, but is updated to actual version on build.</string>
</dict>
</plist>
78 changes: 39 additions & 39 deletions cli5/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -43,45 +43,45 @@ static void regPreRelease(UpdateManifest manifest)

// Build binaries
Console.WriteLine("Building binaries...");
//string buildOutput = runCommand("msbuild ./AstroWall.sln /property:Configuration=Release");
//var outputLines = buildOutput.Split("\n");
//Console.WriteLine(outputLines[outputLines.Length - 2]);
//Console.WriteLine("Binaries built.");

//// Create pkgs
//Console.WriteLine("Creating pkg");
//string shret = runCommand("sh ./scripts/pack.sh", "./AstroWall");
//Console.WriteLine(shret);
//Console.WriteLine("PKGs created");

//// Update manifest
//Release rel = new Release()
//{
// version = newTagLong,
// ReleaseDate = DateTime.Now,
// DirectPKGurl = $"https://github.com/wiegell/AstroWall/releases/download/{newTagShort}/Astro.pkg",
// Description = "Lorem Ipsum",
// isPreRelease = true
//};
//if (manifest.PreReleases == null) manifest.PreReleases = new Release[0];
//manifest.PreReleases = (Release[])manifest.PreReleases.Append(rel).ToArray();
//writeToFile(manifest);

//// Commit manifest
//runCommand($"git add . && git commit -m \\\"Updated manifest with release {newTagLong}\\\"");

//// Push new tag to gh
//Console.WriteLine("Pushing new tag to origin");
//runCommand("git push origin --tags");

//// Upload release
//Console.WriteLine("Uploading release to gh");
//string uploadres = runCommand($"gh release create --generate-notes {newTagShort} ./AstroWall/bin/Package/Astro.pkg");
//Console.WriteLine("Upload res:\n" + uploadres);

//// Push manifest
//string gitPushReturn = runCommand("git push origin master");
//Console.WriteLine("Success: " + gitPushReturn);
string buildOutput = runCommand("msbuild ./AstroWall.sln /property:Configuration=Release");
var outputLines = buildOutput.Split("\n");
Console.WriteLine(outputLines[outputLines.Length - 2]);
Console.WriteLine("Binaries built.");

// Create pkgs
Console.WriteLine("Creating pkg");
string shret = runCommand("sh ./scripts/pack.sh", "./AstroWall");
Console.WriteLine(shret);
Console.WriteLine("PKGs created");

// Update manifest
Release rel = new Release()
{
version = newTagLong,
ReleaseDate = DateTime.Now,
DirectPKGurl = $"https://github.com/wiegell/AstroWall/releases/download/{newTagShort}/Astro.pkg",
Description = "Lorem Ipsum",
isPreRelease = true
};
if (manifest.PreReleases == null) manifest.PreReleases = new Release[0];
manifest.PreReleases = (Release[])manifest.PreReleases.Append(rel).ToArray();
writeToFile(manifest);

// Commit manifest
runCommand($"git add . && git commit -m \\\"Updated manifest with release {newTagLong}\\\"");

// Push new tag to gh
Console.WriteLine("Pushing new tag to origin");
runCommand("git push origin --tags");

// Upload release
Console.WriteLine("Uploading release to gh");
string uploadres = runCommand($"gh release create --generate-notes {newTagShort} ./AstroWall/bin/Package/Astro.pkg");
Console.WriteLine("Upload res:\n" + uploadres);

// Push manifest
string gitPushReturn = runCommand("git push origin master");
Console.WriteLine("Success: " + gitPushReturn);
}
else
{
Expand Down

0 comments on commit e93d1a1

Please sign in to comment.