Skip to content

Instantly share code, notes, and snippets.

View PabloProta's full-sized avatar
🎯
Focusing

Pablo PabloProta

🎯
Focusing
View GitHub Profile
@PabloProta
PabloProta / MainActivity.kt
Created November 1, 2023 00:43
Navigation bug code
import android.os.Bundle
import androidx.activity.ComponentActivity
import androidx.activity.compose.setContent
import androidx.compose.foundation.layout.Arrangement
import androidx.compose.foundation.layout.Column
import androidx.compose.foundation.layout.fillMaxSize
import androidx.compose.foundation.layout.padding
import androidx.compose.material3.ElevatedButton
import androidx.compose.material3.Text
import androidx.compose.runtime.Composable
@PabloProta
PabloProta / build.gradle.kts
Created March 26, 2023 19:54
project/module/build.gradle.kts
android {
buildTypes {
getByName("release") {
// Enables code shrinking, obfuscation, and optimization for only
// your project's release build type.
isMinifyEnabled = true
// Enables resource shrinking, which is performed by the
// Android Gradle plugin.
isShrinkResources = true
@PabloProta
PabloProta / wrapper.properties
Created March 26, 2023 18:31
gradle/wrapper/wrapper.properties
#Sun Mar 26 00:27:13 BRT 2023
distributionBase=GRADLE_USER_HOME
distributionUrl=https\://services.gradle.org/distributions/gradle-7.5-bin.zip
distributionPath=wrapper/dists
zipStorePath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
@PabloProta
PabloProta / local.properties
Created March 26, 2023 17:41
project/local.properties
## This file is automatically generated by Android Studio.
# Do not modify this file -- YOUR CHANGES WILL BE ERASED!
#
# This file should *NOT* be checked into Version Control Systems,
# as it contains information specific to your local configuration.
#
# Location of the SDK. This is only used by Gradle.
# For customization when using a Version Control System, please read the
# header note.
sdk.dir=C\:\\PATH\\IN\\YOUR\\COMPUTER
@PabloProta
PabloProta / gradle.properties
Created March 26, 2023 17:38
project/gradle.properties
# Project-wide Gradle settings.
# IDE (e.g. Android Studio) users:
# Gradle settings configured through the IDE *will override*
# any settings specified in this file.
# For more details on how to configure your build environment visit
# http://www.gradle.org/docs/current/userguide/build_environment.html
# Specifies the JVM arguments used for the daemon process.
# The setting is particularly useful for tweaking memory settings.
org.gradle.jvmargs=-Xmx2048m -Dfile.encoding=UTF-8
# When configured, Gradle will run in incubating parallel mode.
@PabloProta
PabloProta / build.gradle.kts
Last active March 26, 2023 17:21
project/module/build.gradle.kts
plugins {
/**
* This a plugin dependencie for this module that will be added,
* all plugin dependencies here need be included on build settings on top level.
* Different of the dependencies on bottom of this file this plugin is added to
* increase the gradle dsl capabitility. e.g:
* We added this plugin "com.android.application" to allow the gradle dsl
* access the:
* android {
* // chceck the 21st line...
@PabloProta
PabloProta / build.gradle.kts
Last active March 26, 2023 16:29
project/build.gradle.kts
// This block encapsulates custom properties and makes them available to all
// modules in the project (if your project is multi module). The following are only a few examples of the types
// of properties you can define.
//ps: Google don't recommend this approach, instead is better yo use the Gradle Version Catalog
// check this link: https://developer.android.com/studio/build#project_wide_properties
ext {
extra["sdkVersion"] = 33
// You can also create properties to specify versions for dependencies.
// Having consistent versions between modules can avoid conflicts with behavior.
extra["appcompatVersion"] = "1.6.1"
@PabloProta
PabloProta / settings.gradle.kts
Last active March 26, 2023 15:52
project/settings.gradle.kts
pluginManagement {
/**
* The pluginManagement {repositories {...}} block configures the
* repositories Gradle uses to search or download the Gradle plugins and
* their transitive dependencies. Gradle pre-configures support for remote
* repositories such as JCenter, Maven Central, and Ivy. You can also use
* local repositories or define your own remote repositories. The code below
* defines the Gradle Plugin Portal, Google's Maven repository,
* and the Maven Central Repository as the repositories Gradle should use to look for its