This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pipeline { | |
agent any | |
environment { | |
ANDROID_HOME = "/opt/android-sdk" | |
PATH = "$PATH:${ANDROID_HOME}/tools:${ANDROID_HOME}/tools/bin:${ANDROID_HOME}/platform-tools" | |
COMPANY_A_BASE_URL = credentials("company-a-base-url") | |
COMPANY_A_API_KEY = credentials("company-a-api-key") | |
COMPANY_B_BASE_URL = credentials("company-b-base-url") | |
COMPANY_B_API_KEY = credentials("company-b-api-key") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Check if Android SDK not found (Run on VPS) | |
ls -la /root/Android/Sdk | |
ls -la $ANDROID_HOME | |
# Fix wrong directory Android (Run on VPS) | |
mkdir -p /root/Android/Sdk | |
export ANDROID_HOME="/root/Android/Sdk" | |
sudo mv /root/Android/Sdk /opt/android-sdk | |
sudo chown -R jenkins:jenkins /opt/android-sdk |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Install Jenkins and Java | |
sudo apt-get install jenkins | |
sudo apt install openjdk-17-jre | |
# Make jenkins autostart on launch | |
sudo systemctl enable jenkins | |
# Make jenkins start | |
sudo systemctl start jenkins |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apt update | |
apt install apt-transport-https ca-certificates curl software-properties-common | |
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add - | |
add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu focal stable" | |
apt update |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
internal class AuthRefreshFeature( | |
private val localAuthDataSource: LocalAuthDataSource, | |
private val refreshTokenDataSource: KtorRefreshTokenDataSource, | |
private val localAuthErrorDataSource: LocalAuthErrorDataSource, | |
private val json: Json | |
) { | |
class Config( | |
var localAuthDataSource: LocalAuthDataSource? = null, | |
var refreshTokenDataSource: KtorRefreshTokenDataSource? = null, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Composable | |
fun DesktopWebView() { | |
val finishListener = object : PlatformImpl.FinishListener { | |
override fun idle(implicitExit: Boolean) {} | |
override fun exitCalled() {} | |
} | |
PlatformImpl.addListener(finishListener) | |
println("Desktop Web View start") | |
Window( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class DesktopWebView { | |
public static JFrame renderWebView(String url) { | |
JFrame frame = new JFrame(); | |
final JFXPanel fxPanel = new JFXPanel(); | |
frame.add(fxPanel); | |
frame.setSize(300, 200); | |
frame.setVisible(true); | |
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
struct ExampleView: View { | |
let viewModel: AuthViewModel = AuthViewModel() | |
var body: some View { | |
ObservingView(statePublisher: asPublisher(viewModel.viewStates()), | |
actionPublisher: asPublisher(viewModel.viewActions()), | |
content: { state, action in | |
// your view here | |
}) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Composable | |
fun TagHost( | |
modifier: Modifier = Modifier, | |
verticalPadding: Dp = 24.dp, | |
content: @Composable () -> Unit | |
) { | |
Layout( | |
modifier = modifier, | |
content = content | |
) { measurables, constraints -> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
plugins { | |
id("com.android.application") | |
kotlin("android") | |
kotlin("kapt") | |
id("org.jetbrains.compose") | |
} | |
android { | |
compileSdkVersion(30) | |
buildToolsVersion("30.0.2") |
NewerOlder