Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 1 addition & 6 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1 @@
version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "daily"

70 changes: 41 additions & 29 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -1,36 +1,48 @@
name: Build and Test
name: Build and Deploy JobClick to Google Play

on:
workflow_dispatch:
push:
branches: [main]
pull_request:
branches: [main]
inputs:
track:
description: 'Play Store track to deploy (internal, alpha, beta, production)'
required: true
default: 'internal'

jobs:
build:
name: Build Package
runs-on: windows-2022

env:
Solution_Path: Sample\Auth0MauiApp.sln
build-deploy:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- name: Install Java
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '11'

- name: Install .NET Core
uses: actions/setup-dotnet@v4
with:
dotnet-version: "8"

- name: Install .NET Workloads
run: dotnet workload install maui

- name: Build
run: dotnet build $env:Solution_Path --configuration Release
- name: Checkout code
uses: actions/checkout@v3

- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: '8.x'

- name: Decode keystore
run: |
mkdir -p $HOME/.keystore
echo "${{ secrets.KEYSTORE_BASE64 }}" | base64 -d > $HOME/.keystore/jobclick.keystore

- name: Restore dependencies
run: dotnet restore

- name: Build Android AAB
run: dotnet publish JobClick.csproj -f net8.0-android -c Release -o publish \
/p:AndroidKeyStore=true \
/p:AndroidSigningKeyStore=$HOME/.keystore/jobclick.keystore \
/p:AndroidSigningKeyAlias=${{ secrets.KEY_ALIAS }} \
/p:AndroidSigningKeyPass=${{ secrets.KEY_PASS }} \
/p:AndroidSigningStorePass=${{ secrets.STORE_PASS }} \
/p:AndroidPackageFormat=aab

- name: Upload to Google Play
uses: r0adkll/upload-google-play@v1
with:
serviceAccountJsonPlainText: ${{ secrets.GOOGLE_PLAY_KEY_JSON }}
packageName: com.jobclick.app
releaseFiles: publish/*.aab
track: ${{ github.event.inputs.track }}
status: draft
2 changes: 1 addition & 1 deletion .github/workflows/semgrep.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:
- synchronize
push:
branches:
- main
- main_temp
schedule:
- cron: "30 0 1,15 * *"

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/snyk.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:
- synchronize
push:
branches:
- main
- main_temp
schedule:
- cron: "30 0 1,15 * *"

Expand Down
6 changes: 6 additions & 0 deletions .vs/VSWorkspaceState.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"ExpandedNodes": [
""
],
"PreviewInSolutionExplorer": false
}
Binary file added .vs/auth0-mobile-sample/v17/.wsuo
Binary file not shown.
12 changes: 12 additions & 0 deletions .vs/auth0-mobile-sample/v17/DocumentLayout.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"Version": 1,
"WorkspaceRootPath": "C:\\SourceCode\\auth0-mobile-sample\\",
"Documents": [],
"DocumentGroupContainers": [
{
"Orientation": 0,
"VerticalTabListWidth": 256,
"DocumentGroups": []
}
]
}
4 changes: 2 additions & 2 deletions Sample/Auth0MauiApp/App.xaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<?xml version = "1.0" encoding = "UTF-8" ?>
<Application xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
xmlns:local="clr-namespace:Auth0MauiApp"
x:Class="Auth0MauiApp.App">
xmlns:local="clr-namespace:JobClick"
x:Class="JobClick.App">
<Application.Resources>
<ResourceDictionary>
<ResourceDictionary.MergedDictionaries>
Expand Down
2 changes: 1 addition & 1 deletion Sample/Auth0MauiApp/App.xaml.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
namespace Auth0MauiApp
namespace JobClick
{
public partial class App : Application
{
Expand Down
4 changes: 2 additions & 2 deletions Sample/Auth0MauiApp/AppShell.xaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<?xml version="1.0" encoding="UTF-8" ?>
<Shell
x:Class="Auth0MauiApp.AppShell"
x:Class="JobClick.AppShell"
xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
xmlns:local="clr-namespace:Auth0MauiApp"
xmlns:local="clr-namespace:JobClick"
Shell.FlyoutBehavior="Disabled">

<ShellContent
Expand Down
2 changes: 1 addition & 1 deletion Sample/Auth0MauiApp/AppShell.xaml.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
namespace Auth0MauiApp
namespace JobClick
{
public partial class AppShell : Shell
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,65 +1,76 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net7.0-android;net7.0-ios;net7.0-maccatalyst</TargetFrameworks>
<TargetFrameworks Condition="$([MSBuild]::IsOSPlatform('windows'))">$(TargetFrameworks);net7.0-windows10.0.19041.0</TargetFrameworks>
<OutputType>Exe</OutputType>
<RootNamespace>Auth0MauiApp</RootNamespace>
<UseMaui>true</UseMaui>
<SingleProject>true</SingleProject>
<ImplicitUsings>enable</ImplicitUsings>

<!-- Display name -->
<ApplicationTitle>Auth0MauiApp</ApplicationTitle>

<!-- App Identifier -->
<ApplicationId>com.companyname.Auth0MauiApp</ApplicationId>
<ApplicationIdGuid>8ac2519e-82a6-4584-a7c2-fd8e56cbd40d</ApplicationIdGuid>

<!-- Versions -->
<ApplicationDisplayVersion>1.0</ApplicationDisplayVersion>
<ApplicationVersion>1</ApplicationVersion>

<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'ios'">11.0</SupportedOSPlatformVersion>
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'maccatalyst'">13.1</SupportedOSPlatformVersion>
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'android'">21.0</SupportedOSPlatformVersion>
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'windows'">10.0.17763.0</SupportedOSPlatformVersion>
<TargetPlatformMinVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'windows'">10.0.17763.0</TargetPlatformMinVersion>

<MicrosoftWindowsAppSDKPackageVersion>1.3.230502000</MicrosoftWindowsAppSDKPackageVersion>

<DefaultLanguage>en</DefaultLanguage>
</PropertyGroup>

<PropertyGroup Condition="'$(Configuration)|$(TargetFramework)|$(Platform)'=='Debug|net7.0-ios|AnyCPU'">
<CreatePackage>false</CreatePackage>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(TargetFramework)|$(Platform)'=='Release|net7.0-ios|AnyCPU'">
<CreatePackage>false</CreatePackage>
</PropertyGroup>
<ItemGroup>
<!-- App Icon -->
<MauiIcon Include="Resources\AppIcon\appicon.svg" ForegroundFile="Resources\AppIcon\appiconfg.svg" Color="#512BD4" />

<!-- Splash Screen -->
<MauiSplashScreen Include="Resources\Splash\splash.svg" Color="#512BD4" BaseSize="128,128" />

<!-- Images -->
<MauiImage Include="Resources\Images\*" />
<MauiImage Update="Resources\Images\dotnet_bot.svg" BaseSize="168,208" />

<!-- Custom Fonts -->
<MauiFont Include="Resources\Fonts\*" />

<!-- Raw Assets (also remove the "Resources\Raw" prefix) -->
<MauiAsset Include="Resources\Raw\**" LogicalName="%(RecursiveDir)%(Filename)%(Extension)" />
</ItemGroup>


<ItemGroup>
<PackageReference Include="IdentityModel.OidcClient" Version="5.2.1" />
<PackageReference Include="Microsoft.Extensions.Logging.Debug" Version="7.0.0" />
<PackageReference Include="Auth0.OidcClient.MAUI" Version="1.0.0" />
</ItemGroup>

</Project>
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net9.0-android35.0;net9.0-ios;net9.0-maccatalyst;net9.0-windows10.0.19041.0</TargetFrameworks>
<OutputType>Exe</OutputType>
<RootNamespace>JobClick</RootNamespace>
<UseMaui>true</UseMaui>
<SingleProject>true</SingleProject>
<ImplicitUsings>enable</ImplicitUsings>

<!-- Display name -->
<ApplicationTitle>JobClick</ApplicationTitle>

<!-- App Identifier -->
<ApplicationId>com.jobclick.app</ApplicationId>
<ApplicationIdGuid>8ac2519e-82a6-4584-a7c2-fd8e56cbd40d</ApplicationIdGuid>

<!-- Versions -->
<ApplicationDisplayVersion>1.0</ApplicationDisplayVersion>
<ApplicationVersion>1</ApplicationVersion>

<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'ios'">11.0</SupportedOSPlatformVersion>
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'maccatalyst'">13.1</SupportedOSPlatformVersion>
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'android'">21.0</SupportedOSPlatformVersion>
<SupportedOSPlatformVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'windows'">10.0.17763.0</SupportedOSPlatformVersion>
<TargetPlatformMinVersion Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'windows'">10.0.17763.0</TargetPlatformMinVersion>

<MicrosoftWindowsAppSDKPackageVersion>1.3.230502000</MicrosoftWindowsAppSDKPackageVersion>

<DefaultLanguage>en</DefaultLanguage>
</PropertyGroup>

<PropertyGroup>
<!-- Use .aab format for Play Store -->
<AndroidPackageFormat>aab</AndroidPackageFormat>

<!-- Enable keystore signing -->
<AndroidKeyStore>true</AndroidKeyStore>
<AndroidSigningKeyStore>jobclick.keystore</AndroidSigningKeyStore>
<AndroidSigningKeyAlias>jobclick</AndroidSigningKeyAlias>
<AndroidSigningKeyPass>your_key_password</AndroidSigningKeyPass>
<AndroidSigningStorePass>your_keystore_password</AndroidSigningStorePass>
</PropertyGroup>

<PropertyGroup Condition="'$(Configuration)|$(TargetFramework)|$(Platform)'=='Debug|net7.0-ios|AnyCPU'">
<CreatePackage>false</CreatePackage>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(TargetFramework)|$(Platform)'=='Release|net7.0-ios|AnyCPU'">
<CreatePackage>false</CreatePackage>
</PropertyGroup>
<ItemGroup>
<!-- App Icon -->
<MauiIcon Include="Resources\AppIcon\appicon.svg" ForegroundFile="Resources\AppIcon\appiconfg.svg" Color="#512BD4" />

<!-- Splash Screen -->
<MauiSplashScreen Include="Resources\Splash\splash.svg" Color="#512BD4" BaseSize="128,128" />

<!-- Images -->
<MauiImage Include="Resources\Images\*" />
<MauiImage Update="Resources\Images\dotnet_bot.svg" BaseSize="168,208" />

<!-- Custom Fonts -->
<MauiFont Include="Resources\Fonts\*" />

<!-- Raw Assets (also remove the "Resources\Raw" prefix) -->
<MauiAsset Include="Resources\Raw\**" LogicalName="%(RecursiveDir)%(Filename)%(Extension)" />
</ItemGroup>


<ItemGroup>
<PackageReference Include="IdentityModel.OidcClient" Version="5.2.1" />
<PackageReference Include="Microsoft.Extensions.Logging.Debug" Version="7.0.0" />
<PackageReference Include="Auth0.OidcClient.MAUI" Version="1.0.0" />
</ItemGroup>

</Project>
2 changes: 1 addition & 1 deletion Sample/Auth0MauiApp/MainPage.xaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="Auth0MauiApp.MainPage">
x:Class="JobClick.MainPage">

<ScrollView>
<VerticalStackLayout
Expand Down
10 changes: 5 additions & 5 deletions Sample/Auth0MauiApp/MainPage.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,17 @@
using IdentityModel.OidcClient;
using IdentityModel.OidcClient.Browser;

namespace Auth0MauiApp
namespace JobClick
{
public partial class MainPage : ContentPage
{
Auth0Client client = new Auth0Client(new Auth0ClientOptions
{
Domain = "",
ClientId = "",
Domain = "dev-jbrriuc5vyjmiwtx.us.auth0.com",
ClientId = "HHkjs4uACOc1O27m3v865SJqbMdAcEfZ",
Scope = "openid profile email",
RedirectUri = "myapp://callback",
PostLogoutRedirectUri = "myapp://callback",
RedirectUri = "jobclick://callback",
PostLogoutRedirectUri = "jobclick://callback",
});

public MainPage()
Expand Down
2 changes: 1 addition & 1 deletion Sample/Auth0MauiApp/MauiProgram.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using Microsoft.Extensions.Logging;

namespace Auth0MauiApp
namespace JobClick
{
public static class MauiProgram
{
Expand Down
2 changes: 1 addition & 1 deletion Sample/Auth0MauiApp/Platforms/Android/MainActivity.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using Android.App;
using Android.Content.PM;

namespace Auth0MauiApp
namespace JobClick
{
[Activity(Theme = "@style/Maui.SplashTheme", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation | ConfigChanges.UiMode | ConfigChanges.ScreenLayout | ConfigChanges.SmallestScreenSize | ConfigChanges.Density)]
public class MainActivity : MauiAppCompatActivity
Expand Down
2 changes: 1 addition & 1 deletion Sample/Auth0MauiApp/Platforms/Android/MainApplication.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using Android.App;
using Android.Runtime;

namespace Auth0MauiApp
namespace JobClick
{
[Application]
public class MainApplication : MauiApplication
Expand Down
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
using Android.App;
using Android.Content.PM;
using Android.Content.PM;
using Android.Content;

namespace Auth0MauiApp
namespace JobClick
{
[Activity(NoHistory = true, LaunchMode = LaunchMode.SingleTop, Exported = true)]
[Activity(NoHistory = true, LaunchMode = LaunchMode.SingleTop, Exported = true)]
[IntentFilter(new[] { Intent.ActionView },
Categories = new[] { Intent.CategoryDefault, Intent.CategoryBrowsable },
DataScheme = CALLBACK_SCHEME)]
public class WebAuthenticatorActivity : Microsoft.Maui.Authentication.WebAuthenticatorCallbackActivity
{
const string CALLBACK_SCHEME = "myapp";
DataScheme = "jobclick", DataHost = "callback")]
public class WebAuthenticatorActivity : Microsoft.Maui.Authentication.WebAuthenticatorCallbackActivity
{
const string CALLBACK_SCHEME = "jobclick";
}

}
2 changes: 1 addition & 1 deletion Sample/Auth0MauiApp/Platforms/MacCatalyst/AppDelegate.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
using Foundation;

namespace Auth0MauiApp
namespace JobClick
{
[Register("AppDelegate")]
public class AppDelegate : MauiUIApplicationDelegate
Expand Down
Loading