Skip to content

Merge pull request #1 #2

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 52 commits into
base: test
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
52 commits
Select commit Hold shift + click to select a range
1fbddd8
Merge pull request #1
plumsoftware Jul 3, 2023
6590b2c
Merge pull request #3 from plumsoftware/test
plumsoftware Nov 9, 2023
35a120e
[~] Исправил баг с удалением заметки
plumsoftware Nov 9, 2023
63470de
[~] Изменил цветовую гамму иконки на желто-оранжевую
plumsoftware Nov 9, 2023
a5801bf
Уведомления о заметках
plumsoftware Nov 13, 2023
474e7f9
Небольшие изменения связанные с базой данных и градле
plumsoftware Nov 16, 2023
e48fb06
[-] Удалил ConstansManager
plumsoftware Nov 19, 2023
885659e
[~] Небольшие изменения в коде
plumsoftware Nov 19, 2023
63519c8
[~] Небольшие изменения в коде
plumsoftware Nov 19, 2023
adfa7a2
[^] Обновил gradle
plumsoftware Dec 17, 2023
478e38c
[~] Небольшие изменения прошлой версии
plumsoftware Jan 3, 2024
269671f
[~] Убрал нативную рекламу
plumsoftware Jan 4, 2024
4f4d5e6
[^] Обновил либы в проекте и грэйдл
plumsoftware Mar 19, 2024
70eb9ff
[~] У меньшил кол-во межстраничной рекламы, вернул нативную рекламу
plumsoftware Mar 19, 2024
c5d4e8d
[~] У меньшил кол-во межстраничной рекламы, вернул нативную рекламу
plumsoftware Mar 19, 2024
97f5ca6
Апнул версию сборки и версию РСЯ
plumsoftware May 7, 2024
a0c4b52
Create README.md
plumsoftware May 27, 2024
7abd6b5
Update README.md
plumsoftware May 27, 2024
b19eb24
Update README.md
plumsoftware May 27, 2024
71f1260
Gradle
plumsoftware Sep 7, 2024
9b4c90f
Git ignore
plumsoftware Sep 7, 2024
2570f07
Git ignore
plumsoftware Sep 7, 2024
9587823
Git ignore
plumsoftware Sep 7, 2024
37c0a6f
Git ignore
plumsoftware Sep 7, 2024
299703b
Git ignore
plumsoftware Sep 7, 2024
d593d81
Git ignore
plumsoftware Sep 7, 2024
d6866de
Merge remote-tracking branch 'origin/master'
plumsoftware Sep 7, 2024
e771390
Gradle
plumsoftware Sep 7, 2024
cf6d76f
Lint
plumsoftware Sep 7, 2024
460be9b
CI
plumsoftware Sep 7, 2024
f1a2ea4
CI
plumsoftware Sep 7, 2024
6214712
CI
plumsoftware Sep 7, 2024
ea3beb5
CI
plumsoftware Sep 7, 2024
6828c77
CI
plumsoftware Sep 7, 2024
992dbc0
CI
plumsoftware Sep 7, 2024
81fcc82
CI
plumsoftware Sep 7, 2024
f6f0261
Архитектура
plumsoftware Sep 8, 2024
5e3d376
Паттерн
plumsoftware Sep 8, 2024
264752a
Паттерн
plumsoftware Sep 9, 2024
13a507b
Паттерн
plumsoftware Sep 9, 2024
b6bac17
Паттерн
plumsoftware Sep 10, 2024
512d95e
Паттерн
plumsoftware Sep 10, 2024
08f608f
Update README.md
plumsoftware Sep 13, 2024
0a877be
Merge pull request #4 from plumsoftware/plumsoftware-update-read-me-1
plumsoftware Sep 13, 2024
61fde2b
Gradle
plumsoftware Nov 1, 2024
c96b237
Merge pull request #5 from plumsoftware/release-v2.0.7
plumsoftware Nov 1, 2024
aa399ee
Android app
plumsoftware Jan 30, 2025
fb5d0c3
Merge pull request #6 from plumsoftware/patch-1
plumsoftware Jan 30, 2025
3590f7e
релиз 2.0.10
plumsoftware Mar 19, 2025
ca8190a
on restart
plumsoftware Mar 19, 2025
f58fe58
релиз 2.0.10 (#7)
plumsoftware Mar 19, 2025
245ee7f
Merge branch 'subrelease-2.0.10'
plumsoftware Mar 19, 2025
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
35 changes: 35 additions & 0 deletions .github/workflows/android lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: android lint

on:
pull_request:
branches:
- 'master'
push:
branches:
- 'master'

jobs:
android-lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 1
- name: set up JDK
uses: actions/setup-java@v4
with:
distribution: zulu
java-version: 21
cache: gradle
- name: Make gradlew executable
run: chmod +x ./gradlew
- name: Create local.properties
run: |
echo "sdk.dir=$(pwd)/android-sdk" >> local.properties
- run: ./gradlew :app:lint
- uses: yutailang0119/action-android-lint@v4
with:
report-path: build/reports/*.xml
ignore-warnings: true
continue-on-error: false
#I love android!
40 changes: 26 additions & 14 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,15 +1,27 @@
*.iml
.gradle
/local.properties
/.idea/caches
/.idea/libraries
/.idea/modules.xml
/.idea/workspace.xml
/.idea/navEditor.xml
/.idea/assetWizardSettings.xml
.DS_Store
/build
/captures
.externalNativeBuild
.cxx
# Gradle files
.gradle/
build/

# Local configuration file (sdk path, etc)
local.properties

# Log/OS Files
*.log

# Android Studio generated files and folders
captures/
.externalNativeBuild/
.cxx/
*.apk
*.aab
output.json

# IntelliJ
*.iml
.idea/
misc.xml
deploymentTargetDropDown.xml
render.experimental.xml

# Android Profiling
*.hprof
3 changes: 0 additions & 3 deletions .idea/.gitignore

This file was deleted.

1 change: 0 additions & 1 deletion .idea/.name

This file was deleted.

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

This file was deleted.

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

This file was deleted.

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

This file was deleted.

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

This file was deleted.

14 changes: 14 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# О проекте
Этот проект начал историю, когда я ещё учился в старших классах школы. Суть простая - создаёшь заметки, ставишь напоминаянию и всё.

# Стек технологий
- Java
- XML android UI
- Foreground service
- MVP
- Clean architecture
- Glide
- РСЯ
- FCM

__Переменные для local.properties не требуются__
1 change: 1 addition & 0 deletions app-data/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
/build
38 changes: 38 additions & 0 deletions app-data/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
plugins {
id("com.android.library")
}

android {
namespace = "ru.plumsoftware.data"
compileSdk = 34

defaultConfig {
minSdk = 22

testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
consumerProguardFiles("consumer-rules.pro")
}

buildTypes {
release {
isMinifyEnabled = false
proguardFiles(
getDefaultProguardFile("proguard-android-optimize.txt"),
"proguard-rules.pro"
)
}
}
compileOptions {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
}
}

dependencies {

implementation("androidx.appcompat:appcompat:1.7.0")
implementation("com.google.android.material:material:1.12.0")
testImplementation("junit:junit:4.13.2")
androidTestImplementation("androidx.test.ext:junit:1.2.1")
androidTestImplementation("androidx.test.espresso:espresso-core:3.6.1")
}
Empty file added app-data/consumer-rules.pro
Empty file.
21 changes: 21 additions & 0 deletions app-data/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
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
package ru.plumsoftware.data;

import android.content.Context;

import androidx.test.platform.app.InstrumentationRegistry;
import androidx.test.ext.junit.runners.AndroidJUnit4;

import org.junit.Test;
import org.junit.runner.RunWith;

import static org.junit.Assert.*;

/**
* Instrumented test, which will execute on an Android device.
*
* @see <a href="http://d.android.com/tools/testing">Testing documentation</a>
*/
@RunWith(AndroidJUnit4.class)
public class ExampleInstrumentedTest {
@Test
public void useAppContext() {
// Context of the app under test.
Context appContext = InstrumentationRegistry.getInstrumentation().getTargetContext();
assertEquals("ru.plumsoftware.data.test", appContext.getPackageName());
}
}
4 changes: 4 additions & 0 deletions app-data/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android">

</manifest>
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
package ru.plumsoftware.data.database;

import android.content.Context;
import android.database.sqlite.SQLiteDatabase;
import android.database.sqlite.SQLiteOpenHelper;

import ru.plumsoftware.data.model.database.DatabaseConstants;

public class SQLiteDatabaseManager extends SQLiteOpenHelper {
private static final int DATABASE_VERSION = 5;
private static final String DATABASE_NAME = DatabaseConstants.DATABASE_NAME;

public SQLiteDatabaseManager(Context context) {
super(context, DATABASE_NAME, null, DATABASE_VERSION);
}

public void onCreate(SQLiteDatabase db) {
db.execSQL(DatabaseConstants.CREATE_NOTES_TABLE);
db.execSQL(DatabaseConstants.CREATE_GROUPS_TABLE);
}

public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) {
if (newVersion > oldVersion) {
String tempTable = "temp_table";
db.execSQL("CREATE TABLE " + tempTable + " AS SELECT * FROM " + DatabaseConstants._NOTES_TABLE_NAME);
db.execSQL(DatabaseConstants.DELETE_NOTES_TABLE);
db.execSQL(DatabaseConstants.CREATE_NOTES_TABLE);

db.execSQL("ALTER TABLE " + tempTable + " ADD " + DatabaseConstants._CHANNEL_ID + " TEXT;");
db.execSQL("ALTER TABLE " + tempTable + " ADD " + DatabaseConstants._IS_NOTIFY + " INTEGER;");

db.execSQL("INSERT INTO " + DatabaseConstants._NOTES_TABLE_NAME + " SELECT * FROM " + tempTable);

db.execSQL("DROP TABLE IF EXISTS " + tempTable);
}
}

public void onDowngrade(SQLiteDatabase db, int oldVersion, int newVersion) {
onUpgrade(db, oldVersion, newVersion);
}
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package ru.plumsoftware.notebook.databases;
package ru.plumsoftware.data.model.database;

import android.provider.BaseColumns;

Expand All @@ -16,6 +16,9 @@ public class DatabaseConstants implements BaseColumns {
public static final String _IS_PINNED = "_is_pinned";
public static final String _IS_LIKED = "_is_liked";

public static final String _CHANNEL_ID = "_notification_channel_id";
public static final String _IS_NOTIFY = "_is_notify";

public static final String CREATE_NOTES_TABLE =
"CREATE TABLE IF NOT EXISTS " + DatabaseConstants._NOTES_TABLE_NAME +
" (" + DatabaseConstants._ID + " INTEGER PRIMARY KEY," +
Expand All @@ -25,7 +28,9 @@ public class DatabaseConstants implements BaseColumns {
DatabaseConstants._NOTE_PROMO + " INTEGER," +
DatabaseConstants._IS_PINNED + " INTEGER," +
DatabaseConstants._NOTE_COLOR + " INTEGER," +
DatabaseConstants._IS_LIKED + " INTEGER)";
DatabaseConstants._IS_LIKED + " INTEGER," +
DatabaseConstants._CHANNEL_ID + " TEXT," +
DatabaseConstants._IS_NOTIFY + " INTEGER)";

public static final String CREATE_GROUPS_TABLE =
"CREATE TABLE IF NOT EXISTS " + DatabaseConstants._GROUPS_TABLE_NAME +
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
package ru.plumsoftware.notebook.data.items;
package ru.plumsoftware.data.model.ui;

import androidx.annotation.ColorRes;

public class Colors {
private int colorRes;
@ColorRes private final int colorRes;

public Colors(int colorRes) {
this.colorRes = colorRes;
Expand Down
Loading