Skip to content

Commit

Permalink
Pegasus-Utils
Browse files Browse the repository at this point in the history
  • Loading branch information
epegasus committed May 9, 2023
0 parents commit b8f26ef
Show file tree
Hide file tree
Showing 96 changed files with 2,952 additions and 0 deletions.
Binary file added .gradle/8.0/checksums/checksums.lock
Binary file not shown.
Binary file not shown.
Empty file.
Binary file added .gradle/8.0/executionHistory/executionHistory.lock
Binary file not shown.
Binary file added .gradle/8.0/fileChanges/last-build.bin
Binary file not shown.
Binary file added .gradle/8.0/fileHashes/fileHashes.bin
Binary file not shown.
Binary file added .gradle/8.0/fileHashes/fileHashes.lock
Binary file not shown.
Empty file added .gradle/8.0/gc.properties
Empty file.
Binary file added .gradle/buildOutputCleanup/buildOutputCleanup.lock
Binary file not shown.
2 changes: 2 additions & 0 deletions .gradle/buildOutputCleanup/cache.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#Tue May 09 15:02:01 PKT 2023
gradle.version=8.0
Empty file added .gradle/vcs-1/gc.properties
Empty file.
1 change: 1 addition & 0 deletions .idea/.name

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions .idea/compiler.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

18 changes: 18 additions & 0 deletions .idea/gradle.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions .idea/kotlinc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 10 additions & 0 deletions .idea/misc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions .idea/vcs.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

129 changes: 129 additions & 0 deletions .idea/workspace.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

35 changes: 35 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
[![](https://jitpack.io/v/epegasus/PegasusUtils.svg)](https://jitpack.io/#epegasus/PegasusUtils)
# Pegasus-Utils

Android Util classes

This library contains numerous functions and extension functions designed to accelerate the coding process, and it will continue to expand with additional functions over time.

## Getting Started

### Step 1

Add maven repository in project level build.gradle or in latest project setting.gradle file
```
repositories {
google()
mavenCentral()
maven { url "https://jitpack.io" }
}
```

### Step 2

Add inappbilling dependencies in App level build.gradle.
```
dependencies {
implementation 'com.github.epegasus:PegasusUtils:1.0.0'
}
```

### Features

1) PegasusBitmapUtils (bitmap utils)
2) PegasusFileUtils (file utils)
3) PegasusDateUtils (formating dates)
4) PegasusHelperUtils (helpers)
1 change: 1 addition & 0 deletions app/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
/build
46 changes: 46 additions & 0 deletions app/build.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
plugins {
id 'com.android.application'
id 'org.jetbrains.kotlin.android'
id 'kotlin-kapt'
}

android {
namespace 'dev.pegasus.utils.sample'
compileSdk 33

defaultConfig {
applicationId "dev.pegasus.utils.sample"
minSdk 23
targetSdk 33
versionCode 1
versionName "1.0"
}

buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_17
targetCompatibility JavaVersion.VERSION_17
}
kotlinOptions {
jvmTarget = '17'
}
buildFeatures {
viewBinding true
dataBinding true
}
}

dependencies {
implementation project(path: ':pegutils')

implementation 'androidx.core:core-ktx:1.10.0'
implementation 'androidx.appcompat:appcompat:1.6.1'
implementation 'com.google.android.material:material:1.8.0'
implementation 'androidx.constraintlayout:constraintlayout:2.1.4'

}
21 changes: 21 additions & 0 deletions app/proguard-rules.pro
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Add project specific ProGuard rules here.
# You can control the set of applied configuration files using the
# proguardFiles setting in build.gradle.
#
# For more details, see
# http://developer.android.com/guide/developing/tools/proguard.html

# If your project uses WebView with JS, uncomment the following
# and specify the fully qualified class name to the JavaScript interface
# class:
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
# public *;
#}

# Uncomment this to preserve the line number information for
# debugging stack traces.
#-keepattributes SourceFile,LineNumberTable

# If you keep the line number information, uncomment this to
# hide the original source file name.
#-renamesourcefileattribute SourceFile
34 changes: 34 additions & 0 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools">

<application
android:allowBackup="true"
android:dataExtractionRules="@xml/data_extraction_rules"
android:fullBackupContent="@xml/backup_rules"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="true"
android:theme="@style/Theme.PegasusUtils"
tools:targetApi="31">
<activity
android:name=".activity.BitmapActivity"
android:exported="false" />
<activity
android:name=".activity.DateActivity"
android:exported="false" />
<activity
android:name=".activity.FileActivity"
android:exported="false" />
<activity
android:name=".MainActivity"
android:exported="true">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>

</manifest>
23 changes: 23 additions & 0 deletions app/src/main/java/dev/pegasus/utils/sample/MainActivity.kt
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
package dev.pegasus.utils.sample

import android.content.Intent
import android.os.Bundle
import androidx.appcompat.app.AppCompatActivity
import dev.pegasus.utils.sample.activity.BitmapActivity
import dev.pegasus.utils.sample.activity.DateActivity
import dev.pegasus.utils.sample.activity.FileActivity
import dev.pegasus.utils.sample.databinding.ActivityMainBinding

class MainActivity : AppCompatActivity() {

private val binding by lazy { ActivityMainBinding.inflate(layoutInflater) }

override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
setContentView(binding.root)

binding.mbBitmapMain.setOnClickListener { startActivity(Intent(this, BitmapActivity::class.java)) }
binding.mbDateMain.setOnClickListener { startActivity(Intent(this, DateActivity::class.java)) }
binding.mbFileMain.setOnClickListener { startActivity(Intent(this, FileActivity::class.java)) }
}
}
Loading

0 comments on commit b8f26ef

Please sign in to comment.