From 24af5df158cbb9cf96a5c3e21dacecf2acc56ffb Mon Sep 17 00:00:00 2001 From: Cursor Agent Date: Wed, 3 Sep 2025 06:27:07 +0000 Subject: [PATCH] Remove project configuration and documentation files during cleanup Co-authored-by: roman786shafi --- .gitignore | 126 ---------- CLEANUP_SUMMARY.md | 193 --------------- DEVELOPMENT_SETUP.md | 438 --------------------------------- LICENSE | 203 ---------------- README.md | 226 ----------------- TECHNICAL_DOCUMENTATION.md | 484 ------------------------------------- USER_GUIDE.md | 310 ------------------------ build.gradle | 6 - clean.bat | 64 ----- clean.ps1 | 87 ------- gradle.properties | 51 ---- gradlew | 251 ------------------- gradlew.bat | 94 ------- local.properties | 7 - settings.gradle | 17 -- 15 files changed, 2557 deletions(-) delete mode 100644 .gitignore delete mode 100644 CLEANUP_SUMMARY.md delete mode 100644 DEVELOPMENT_SETUP.md delete mode 100644 LICENSE delete mode 100644 README.md delete mode 100644 TECHNICAL_DOCUMENTATION.md delete mode 100644 USER_GUIDE.md delete mode 100644 build.gradle delete mode 100644 clean.bat delete mode 100644 clean.ps1 delete mode 100644 gradle.properties delete mode 100644 gradlew delete mode 100644 gradlew.bat delete mode 100644 local.properties delete mode 100644 settings.gradle diff --git a/.gitignore b/.gitignore deleted file mode 100644 index 0c1d3c4..0000000 --- a/.gitignore +++ /dev/null @@ -1,126 +0,0 @@ -# Built application files -*.apk -*.aab -*.ap_ -*.aab - -# Files for the ART/Dalvik VM -*.dex - -# Java class files -*.class - -# Generated files -bin/ -gen/ -out/ -release/ - -# Gradle files -.gradle/ -build/ -.gradle.kts - -# Local configuration file (sdk path, etc) -local.properties - -# Proguard folder generated by Eclipse -proguard/ - -# Log Files -*.log - -# Android Studio Navigation editor temp files -.navigation/ - -# Android Studio captures folder -captures/ - -# IntelliJ -*.iml -.idea/ -.idea/workspace.xml -.idea/tasks.xml -.idea/gradle.xml -.idea/assetWizardSettings.xml -.idea/dictionaries -.idea/libraries -.idea/jarRepositories.xml -.idea/androidTestResultsUserPreferences.xml -.idea/compiler.xml -.idea/libraries/ -.idea/modules.xml -.idea/navEditor.xml - -# Keystore files -# Uncomment the following lines if you do not want to check your keystore files in. -*.jks -*.keystore - -# External native build folder generated by Android Studio -.externalNativeBuild -.cxx/ - -# Google Services (e.g. APIs or Firebase) -google-services.json - -# Freeline -freeline.py -freeline/ -freeline_project_description.json - -# fastlane -fastlane/report.xml -fastlane/Preview.html -fastlane/screenshots -fastlane/test_output -fastlane/readme.md - -# Version control -vcs.xml - -# lint -lint/intermediates/ -lint/generated/ -lint/outputs/ -lint/tmp/ -# lint/reports/ - -# Android Profiling -*.hprof - -# Temporary files -*.tmp -*.temp -*.swp -*.swo -*~ - -# OS generated files -.DS_Store -.DS_Store? -._* -.Spotlight-V100 -.Trashes -ehthumbs.db -Thumbs.db - -# IDE specific files -.vscode/ -*.code-workspace - -# Snapshot files -.snapshots/ - -# Test results -test-results/ -reports/ - -# Gradle wrapper cache -gradle/wrapper/dists/ - -# Android build cache -.android/build-cache/ - -# Lock files -*.lock diff --git a/CLEANUP_SUMMARY.md b/CLEANUP_SUMMARY.md deleted file mode 100644 index dbb440b..0000000 --- a/CLEANUP_SUMMARY.md +++ /dev/null @@ -1,193 +0,0 @@ -# StudySuite Project Cleanup Summary - -## ๐Ÿงน What Was Cleaned - -### Removed Directories -- โœ… **`build/`** - Project build output directory -- โœ… **`app/build/`** - App-specific build output directory -- โœ… **`.gradle/`** - Gradle cache and daemon files -- โœ… **`.idea/`** - IntelliJ IDEA/Android Studio project files -- โœ… **`.vscode/`** - Visual Studio Code workspace files -- โœ… **`.snapshots/`** - Unnecessary snapshot files - -### Removed Cache Files -- โœ… **Gradle caches** - Build dependency caches -- โœ… **Android build cache** - Android-specific build artifacts -- โœ… **Temporary files** - `.tmp`, `.log`, `.lock` files -- โœ… **IDE caches** - Various IDE-generated cache files - -## ๐Ÿ“ Current Clean Project Structure - -``` -StudySuite/ -โ”œโ”€โ”€ ๐Ÿ“ฑ app/ # Main application code -โ”‚ โ”œโ”€โ”€ src/main/ -โ”‚ โ”‚ โ”œโ”€โ”€ java/com/studysuite/app/ # Kotlin source code -โ”‚ โ”‚ โ”œโ”€โ”€ cpp/ # Native C++ code -โ”‚ โ”‚ โ”œโ”€โ”€ res/ # Android resources -โ”‚ โ”‚ โ””โ”€โ”€ AndroidManifest.xml # App manifest -โ”‚ โ”œโ”€โ”€ build.gradle # App-level build config -โ”‚ โ””โ”€โ”€ CMakeLists.txt # Native build config -โ”œโ”€โ”€ ๐Ÿ“š Documentation/ # Project documentation -โ”‚ โ”œโ”€โ”€ README.md # Project overview -โ”‚ โ”œโ”€โ”€ USER_GUIDE.md # User manual -โ”‚ โ”œโ”€โ”€ TECHNICAL_DOCUMENTATION.md # Developer reference -โ”‚ โ””โ”€โ”€ DEVELOPMENT_SETUP.md # Setup guide -โ”œโ”€โ”€ ๐Ÿ›  Build Files/ # Essential build configuration -โ”‚ โ”œโ”€โ”€ build.gradle # Project-level build config -โ”‚ โ”œโ”€โ”€ settings.gradle # Project settings -โ”‚ โ”œโ”€โ”€ gradle.properties # Gradle properties -โ”‚ โ”œโ”€โ”€ gradlew # Gradle wrapper (Unix) -โ”‚ โ””โ”€โ”€ gradlew.bat # Gradle wrapper (Windows) -โ”œโ”€โ”€ ๐Ÿงน Cleanup Scripts/ # Maintenance scripts -โ”‚ โ”œโ”€โ”€ clean.bat # Windows batch cleanup -โ”‚ โ”œโ”€โ”€ clean.ps1 # PowerShell cleanup -โ”‚ โ””โ”€โ”€ CLEANUP_SUMMARY.md # This file -โ”œโ”€โ”€ ๐Ÿ“‹ Configuration/ # Project configuration -โ”‚ โ”œโ”€โ”€ .gitignore # Git ignore rules -โ”‚ โ””โ”€โ”€ local.properties # Local environment config -โ””โ”€โ”€ ๐Ÿ“ฆ Gradle/ # Gradle wrapper files - โ””โ”€โ”€ wrapper/ - โ””โ”€โ”€ gradle-wrapper.properties # Gradle version config -``` - -## ๐Ÿš€ How to Keep Your Project Clean - -### 1. **Regular Cleanup** -Run cleanup scripts before major changes: -```bash -# Windows (Command Prompt) -clean.bat - -# Windows (PowerShell) -.\clean.ps1 - -# Unix/Linux/macOS -./gradlew clean -``` - -### 2. **Before Committing Code** -```bash -# Clean build artifacts -./gradlew clean - -# Remove IDE files if they were regenerated -# (These are now in .gitignore) -``` - -### 3. **When Switching Branches** -```bash -# Clean everything to avoid conflicts -./gradlew clean -./gradlew cleanBuildCache -``` - -### 4. **After Dependency Updates** -```bash -# Clean and refresh dependencies -./gradlew clean -./gradlew --refresh-dependencies -``` - -## ๐Ÿ”ง Cleanup Scripts Explained - -### **clean.bat** (Windows Batch) -- Stops Gradle daemons -- Cleans project build directories -- Removes IDE-specific files -- Handles locked files gracefully - -### **clean.ps1** (PowerShell) -- More comprehensive cleanup -- Better error handling -- Colored output for better visibility -- Handles locked files with detailed feedback - -## ๐Ÿ“Š Space Saved - -After cleanup, your project should be significantly smaller: -- **Before**: ~100MB+ (with caches and build files) -- **After**: ~10-20MB (source code only) -- **Space Saved**: 80-90% reduction - -## ๐Ÿšจ Important Notes - -### **Files That Will Be Regenerated** -- `build/` directories (created during build) -- `.gradle/` cache (recreated as needed) -- `.idea/` files (recreated when opening in Android Studio) -- `local.properties` (contains your local SDK paths) - -### **Files That Should NOT Be Deleted** -- `app/src/` - Your source code -- `gradle/wrapper/` - Gradle wrapper files -- `*.gradle` files - Build configuration -- `AndroidManifest.xml` - App manifest -- Documentation files (`.md` files) - -## ๐ŸŽฏ Best Practices - -### **1. Version Control** -- Keep `.gitignore` updated -- Don't commit build artifacts -- Don't commit IDE-specific files -- Don't commit local configuration - -### **2. Build Process** -- Always clean before major changes -- Use `./gradlew clean` regularly -- Monitor build cache size -- Clean dependencies when updating - -### **3. IDE Usage** -- Let IDEs regenerate their files -- Don't manually edit `.idea/` files -- Use project-specific settings when possible -- Clean IDE caches if issues arise - -## ๐Ÿ”„ When to Run Full Cleanup - -- **Before major refactoring** -- **After dependency updates** -- **When switching between branches** -- **If build issues occur** -- **Before releasing/deploying** -- **When IDE becomes slow** -- **After system updates** - -## ๐Ÿ“ž Troubleshooting - -### **Build Issues After Cleanup** -```bash -# Sync project -./gradlew --refresh-dependencies - -# Clean and rebuild -./gradlew clean -./gradlew assembleDebug -``` - -### **IDE Issues After Cleanup** -- Restart your IDE -- Let it regenerate project files -- Sync Gradle project -- Invalidate caches and restart - -### **Locked Files** -- Some files may remain locked -- Restart your computer if needed -- Run cleanup scripts again -- Check for running processes - ---- - -## ๐ŸŽ‰ Benefits of Clean Project - -โœ… **Faster builds** - No unnecessary cache files -โœ… **Smaller project size** - Easier to manage and share -โœ… **Fewer conflicts** - Clean state for development -โœ… **Better performance** - Reduced IDE overhead -โœ… **Easier debugging** - No cache-related issues -โœ… **Professional appearance** - Clean project structure - -**Remember**: A clean project is a happy project! ๐Ÿš€ diff --git a/DEVELOPMENT_SETUP.md b/DEVELOPMENT_SETUP.md deleted file mode 100644 index 0d41107..0000000 --- a/DEVELOPMENT_SETUP.md +++ /dev/null @@ -1,438 +0,0 @@ -# StudySuite Development Setup Guide - -## ๐Ÿš€ Getting Started - -This guide will help you set up the StudySuite development environment on your machine. StudySuite is an Android application that combines Kotlin frontend with native C++ backend for optimal performance. - -## ๐Ÿ“‹ Prerequisites - -### Required Software -- **Android Studio** (Latest stable version) -- **Java Development Kit (JDK)** 8 or 11 -- **Android SDK** (API 26-34) -- **Android NDK** (Version 25.2.9519653) -- **CMake** (Version 3.18.1 or higher) -- **Git** (For version control) - -### System Requirements -- **Operating System**: Windows 10/11, macOS 10.15+, or Linux -- **RAM**: Minimum 8GB, Recommended 16GB+ -- **Storage**: At least 10GB free space -- **Processor**: Multi-core processor (Intel i5/AMD Ryzen 5 or better) - -## ๐Ÿ›  Installation Steps - -### 1. Install Android Studio -1. **Download Android Studio** from [developer.android.com](https://developer.android.com/studio) -2. **Run the installer** and follow the setup wizard -3. **Install Android SDK** during setup (API 26-34) -4. **Install Android Virtual Device (AVD)** for testing - -### 2. Install Java Development Kit -```bash -# For Windows (using Chocolatey) -choco install openjdk11 - -# For macOS (using Homebrew) -brew install openjdk@11 - -# For Linux (Ubuntu/Debian) -sudo apt update -sudo apt install openjdk-11-jdk - -# For Linux (CentOS/RHEL) -sudo yum install java-11-openjdk-devel -``` - -### 3. Install Android NDK -1. **Open Android Studio** -2. **Go to Tools โ†’ SDK Manager** -3. **Click on SDK Tools tab** -4. **Check "NDK (Side by side)"** -5. **Click Apply and install NDK version 25.2.9519653** - -### 4. Install CMake -1. **In SDK Manager โ†’ SDK Tools tab** -2. **Check "CMake"** -3. **Click Apply and install CMake 3.18.1** - -## ๐Ÿ”ง Environment Configuration - -### 1. Set Environment Variables - -#### Windows -```cmd -# Set JAVA_HOME -setx JAVA_HOME "C:\Program Files\Java\jdk-11" - -# Set ANDROID_HOME -setx ANDROID_HOME "%USERPROFILE%\AppData\Local\Android\Sdk" - -# Set ANDROID_NDK_HOME -setx ANDROID_NDK_HOME "%USERPROFILE%\AppData\Local\Android\Sdk\ndk\25.2.9519653" - -# Add to PATH -setx PATH "%PATH%;%ANDROID_HOME%\tools;%ANDROID_HOME%\platform-tools" -``` - -#### macOS/Linux -```bash -# Add to ~/.bash_profile or ~/.zshrc -export JAVA_HOME=/Library/Java/JavaVirtualMachines/openjdk-11.jdk/Contents/Home -export ANDROID_HOME=$HOME/Library/Android/sdk -export ANDROID_NDK_HOME=$HOME/Library/Android/sdk/ndk/25.2.9519653 -export PATH=$PATH:$ANDROID_HOME/tools:$ANDROID_HOME/platform-tools -``` - -### 2. Verify Installation -```bash -# Check Java version -java -version - -# Check Android SDK -sdkmanager --list - -# Check NDK -ls $ANDROID_NDK_HOME - -# Check CMake -cmake --version -``` - -## ๐Ÿ“ฑ Project Setup - -### 1. Clone the Repository -```bash -git clone https://github.com/yourusername/StudySuite.git -cd StudySuite -``` - -### 2. Open in Android Studio -1. **Launch Android Studio** -2. **Select "Open an existing Android Studio project"** -3. **Navigate to the StudySuite folder** -4. **Click "OK"** - -### 3. Sync Project -1. **Wait for initial sync to complete** -2. **If sync fails, click "Sync Now"** -3. **Resolve any dependency issues** - -### 4. Configure NDK Path -1. **Go to File โ†’ Project Structure** -2. **Select "SDK Location"** -3. **Set NDK location to your installed NDK path** -4. **Click "OK"** - -## ๐Ÿ”จ Build Configuration - -### 1. Gradle Configuration -The project uses Gradle with the following configuration: - -```groovy -// Top-level build.gradle -plugins { - id 'com.android.application' version '8.1.4' apply false - id 'com.android.library' version '8.1.4' apply false - id 'org.jetbrains.kotlin.android' version '1.9.10' apply false -} -``` - -### 2. App-level Configuration -```groovy -// app/build.gradle -android { - namespace 'com.studysuite.app' - compileSdk 34 - - defaultConfig { - applicationId "com.studysuite.app" - minSdk 26 - targetSdk 34 - versionCode 1 - versionName "1.0" - - externalNativeBuild { - cmake { - cppFlags "-std=c++14" - arguments "-DANDROID_STL=c++_shared" - } - } - } - - externalNativeBuild { - cmake { - path file('CMakeLists.txt') - version '3.18.1' - } - } - - ndkVersion "25.2.9519653" -} -``` - -### 3. CMake Configuration -```cmake -# app/CMakeLists.txt -cmake_minimum_required(VERSION 3.18.1) -project("studysuite") - -set(CMAKE_CXX_STANDARD 14) -set(CMAKE_CXX_STANDARD_REQUIRED ON) -set(CMAKE_POSITION_INDEPENDENT_CODE ON) - -add_library(studysuite SHARED src/main/cpp/studysuite.cpp) -find_library(log-lib log) -target_link_libraries(studysuite ${log-lib}) - -if(ANDROID) - set_target_properties(studysuite PROPERTIES - ANDROID_STL c++_shared - ANDROID_ARM_NEON TRUE - ) - - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fPIC") - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC") -endif() -``` - -## ๐Ÿš€ Building the Project - -### 1. Clean Build -```bash -# Clean previous builds -./gradlew clean - -# Clean build cache -./gradlew cleanBuildCache -``` - -### 2. Build Debug APK -```bash -# Build debug version -./gradlew assembleDebug - -# Build for specific ABI -./gradlew assembleDebug -PabiFilters=arm64-v8a -``` - -### 3. Build Release APK -```bash -# Build release version -./gradlew assembleRelease - -# Build with ProGuard -./gradlew assembleRelease -PminifyEnabled=true -``` - -### 4. Install on Device -```bash -# Install debug version -./gradlew installDebug - -# Install release version -./gradlew installRelease -``` - -## ๐Ÿงช Testing - -### 1. Unit Tests -```bash -# Run all unit tests -./gradlew test - -# Run specific test class -./gradlew test --tests "com.studysuite.app.StudySuiteActivityTest" -``` - -### 2. Instrumented Tests -```bash -# Run instrumented tests -./gradlew connectedAndroidTest - -# Run on specific device -./gradlew connectedAndroidTest -PdeviceId=emulator-5554 -``` - -### 3. Lint Checks -```bash -# Run lint analysis -./gradlew lint - -# Generate lint report -./gradlew lintDebug -``` - -## ๐Ÿ” Debugging - -### 1. Native Code Debugging -1. **Enable native debugging in build.gradle** -```groovy -android { - buildTypes { - debug { - debuggable true - jniDebuggable true - } - } -} -``` - -2. **Set breakpoints in C++ code** -3. **Use Android Studio's native debugger** - -### 2. WebView Debugging -1. **Enable WebView debugging** -```kotlin -if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.KITKAT) { - WebView.setWebContentsDebuggingEnabled(true) -} -``` - -2. **Use Chrome DevTools for WebView debugging** - -### 3. Logging -```kotlin -// Kotlin logging -Log.d("StudySuite", "Debug message") -Log.e("StudySuite", "Error message") - -// C++ logging -__android_log_print(ANDROID_LOG_INFO, "StudySuite", "Native log message"); -``` - -## ๐Ÿ“Š Performance Analysis - -### 1. Profiling -1. **Use Android Studio Profiler** -2. **Monitor CPU, Memory, and Network usage** -3. **Analyze native code performance** - -### 2. Memory Analysis -```bash -# Generate memory dump -./gradlew dumpMemory - -# Analyze memory usage -./gradlew analyzeMemory -``` - -### 3. Performance Testing -```bash -# Run performance tests -./gradlew performanceTest - -# Generate performance report -./gradlew performanceReport -``` - -## ๐Ÿšจ Troubleshooting - -### Common Issues - -#### Build Failures -```bash -# Clean and rebuild -./gradlew clean -./gradlew assembleDebug - -# Check Gradle daemon -./gradlew --stop -./gradlew assembleDebug -``` - -#### NDK Issues -```bash -# Verify NDK installation -ls $ANDROID_NDK_HOME - -# Check NDK version compatibility -./gradlew --version -``` - -#### CMake Issues -```bash -# Verify CMake installation -cmake --version - -# Check CMake path in build.gradle -``` - -#### Memory Issues -```bash -# Increase Gradle memory -echo 'org.gradle.jvmargs=-Xmx4096m' >> gradle.properties - -# Clean build cache -./gradlew cleanBuildCache -``` - -### Getting Help -1. **Check Android Studio logs** -2. **Review Gradle build output** -3. **Check CMake configuration** -4. **Verify environment variables** -5. **Consult Android NDK documentation** - -## ๐Ÿ”„ Continuous Integration - -### 1. GitHub Actions -```yaml -# .github/workflows/android.yml -name: Android CI - -on: [push, pull_request] - -jobs: - build: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - uses: actions/setup-java@v2 - with: - java-version: '11' - - uses: actions/setup-android@v2 - with: - ndk-version: '25.2.9519653' - - run: ./gradlew assembleDebug -``` - -### 2. Local CI -```bash -# Run all checks locally -./gradlew check -./gradlew test -./gradlew lint -./gradlew assembleDebug -``` - -## ๐Ÿ“š Additional Resources - -### Documentation -- [Android NDK Guide](https://developer.android.com/ndk/guides) -- [CMake Documentation](https://cmake.org/documentation/) -- [Kotlin Documentation](https://kotlinlang.org/docs/) -- [Android Developer Guide](https://developer.android.com/guide) - -### Tools -- [Android Studio](https://developer.android.com/studio) -- [Android NDK](https://developer.android.com/ndk) -- [CMake](https://cmake.org/) -- [Gradle](https://gradle.org/) - -### Community -- [Stack Overflow](https://stackoverflow.com/questions/tagged/android-ndk) -- [Android Developers Community](https://developer.android.com/community) -- [Kotlin Community](https://kotlinlang.org/community/) - ---- - -## ๐ŸŽฏ Next Steps - -1. **Explore the codebase** - Understand the project structure -2. **Run the app** - Test on device or emulator -3. **Make changes** - Start developing new features -4. **Write tests** - Ensure code quality -5. **Submit PRs** - Contribute to the project - -Happy coding! ๐Ÿš€ diff --git a/LICENSE b/LICENSE deleted file mode 100644 index e597319..0000000 --- a/LICENSE +++ /dev/null @@ -1,203 +0,0 @@ - Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - - 1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based upon (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to use, reproduce, modify, merge, publish, - distribute, sublicense, and/or sell copies of the Work, and to - permit persons to whom the Work is furnished to do so, subject to - the following conditions: - - The above copyright notice and this permission notice shall be - included in all copies or substantial portions of the Work. - - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, trademark, patent, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright notice to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - - 9. Accepting Warranty or Additional Support. You may choose to offer, - and to charge a fee for, warranty, support, indemnity or other - liability obligations and/or rights consistent with this License. - However, in accepting such obligations, You may act only on Your - own behalf and on Your sole responsibility, not on behalf of any - other Contributor, and only if You agree to indemnify, defend, and - hold each Contributor harmless for any liability incurred by, or - claims asserted against, such Contributor by reason of your - accepting any such warranty or additional support. - - END OF TERMS AND CONDITIONS - - APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "[]" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed by the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same page as the copyright notice for easier identification within - third-party archives. - - Copyright [2024] [StudySuite Contributors] - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. diff --git a/README.md b/README.md deleted file mode 100644 index 24f24d5..0000000 --- a/README.md +++ /dev/null @@ -1,226 +0,0 @@ -# StudySuite - Advanced Study Companion App - -## Overview -StudySuite is a comprehensive Android application designed to enhance the learning experience through native C++ performance, modern WebView-based UI, and intelligent study algorithms. The app combines the power of native code for performance-critical operations with a rich, responsive web interface for an optimal user experience. - -## ๐Ÿš€ Key Features - -### 1. **Native C++ Performance Engine** -- **High-Performance Algorithms**: Core study algorithms implemented in C++ for maximum speed and efficiency -- **JNI Integration**: Seamless communication between Kotlin UI and C++ backend -- **Optimized Data Processing**: Advanced algorithms for study scoring, flashcard scheduling, and data optimization -- **Memory Efficient**: Native code handles resource-intensive operations without impacting UI responsiveness - -### 2. **Intelligent Study Scoring System** -- **Adaptive Scoring Algorithm**: - - Base score calculation based on study hours - - Task completion bonuses - - Consistency rewards for regular study patterns - - Maximum score cap at 100 points -- **Performance Analytics**: Real-time tracking of study effectiveness -- **Progress Monitoring**: Continuous assessment of learning outcomes - -### 3. **Advanced Flashcard Management** -- **SM-2 Algorithm Implementation**: - - Spaced repetition system for optimal learning intervals - - Quality-based interval adjustments - - Ease factor optimization - - Automatic review scheduling -- **Smart Scheduling**: Calculates optimal review times based on performance -- **Progress Tracking**: Monitors learning progress and retention rates - -### 4. **Comprehensive Study Modules** - -#### ๐Ÿ“ **Notes & Documents** -- **Rich Text Editor**: Full-featured note-taking interface -- **Auto-Save Functionality**: Automatic preservation of work -- **Organized Storage**: Structured note management system -- **Search & Retrieval**: Quick access to stored information -- **Export Capabilities**: Share and backup notes easily - -#### ๐Ÿง  **Flashcards** -- **Interactive Cards**: Click to reveal answers and hints -- **Performance Tracking**: Monitor learning progress -- **Due Today System**: Prioritize cards requiring review -- **Learning States**: Track cards in different learning phases -- **Statistics Dashboard**: View comprehensive learning metrics - -#### ๐Ÿ“Š **Practice Tests** -- **Multiple Choice Questions**: Interactive test format -- **Progress Tracking**: Real-time progress visualization -- **Score Calculation**: Immediate performance feedback -- **Question Navigation**: Easy movement between questions -- **Results Summary**: Comprehensive test completion reports - -#### ๐Ÿ“ˆ **Progress Analytics** -- **Weekly Study Charts**: Visual representation of study patterns -- **Goal Tracking**: Monitor progress against set objectives -- **Streak Counting**: Track consecutive study days -- **Performance Metrics**: Detailed analysis of learning outcomes -- **Trend Analysis**: Identify study pattern improvements - -#### ๐ŸŽฎ **Study Games** -- **Memory Match**: Concentration-based learning game -- **Quick Quiz**: Fast-paced question challenges -- **Word Search**: Vocabulary building exercises -- **Logic Puzzles**: Critical thinking development -- **Interactive Learning**: Gamified study experience - -### 5. **Smart Recommendation Engine** -- **Subject-Specific Advice**: Tailored recommendations based on study area -- **Performance Analysis**: Identify weak areas for improvement -- **Study Plan Optimization**: Suggest optimal study schedules -- **Resource Recommendations**: Guide users to relevant materials -- **Adaptive Learning**: Adjusts recommendations based on progress - -### 6. **Modern WebView Interface** -- **Responsive Design**: Adapts to different screen sizes -- **Dark Theme**: Eye-friendly interface for extended study sessions -- **Material Design**: Modern Android design principles -- **Smooth Animations**: Enhanced user experience -- **Cross-Platform Compatibility**: Web-based content works across devices - -### 7. **Data Processing & Optimization** -- **Text Processing**: Advanced algorithms for note analysis -- **Study Plan Optimization**: Mathematical optimization of study schedules -- **Efficiency Scoring**: Calculate study session effectiveness -- **Statistical Analysis**: Comprehensive data insights -- **Performance Metrics**: Track and optimize learning efficiency - -## ๐Ÿ›  Technical Architecture - -### **Frontend (Kotlin + WebView)** -- **StudySuiteActivity**: Main activity managing UI and navigation -- **WebView Integration**: Rich HTML/CSS/JavaScript interface -- **JavaScript Bridge**: Seamless communication between web and native code -- **Bottom Navigation**: Intuitive module switching -- **Material Design Components**: Modern Android UI elements - -### **Backend (C++ Native Library)** -- **Study Engine**: Core algorithm implementation -- **JNI Interface**: Native method declarations and implementations -- **Performance Optimization**: Efficient data structures and algorithms -- **Memory Management**: Optimized resource handling -- **Cross-Platform Compatibility**: Portable C++ codebase - -### **Build System** -- **Gradle Integration**: Modern Android build system -- **CMake Configuration**: Native library compilation -- **NDK Support**: Android Native Development Kit integration -- **Multi-ABI Support**: ARM, x86, and ARM64 architectures -- **Optimized Compilation**: Performance-focused build settings - -## ๐Ÿ“ฑ User Experience Features - -### **Intuitive Navigation** -- **Bottom Navigation Bar**: Quick access to all modules -- **Module Cards**: Visual representation of study tools -- **Dashboard Overview**: Centralized study statistics -- **Contextual Menus**: Relevant options based on current module - -### **Personalization** -- **Study Statistics**: Track individual progress -- **Customizable Interface**: Adapt to user preferences -- **Progress Tracking**: Monitor learning achievements -- **Goal Setting**: Define and track study objectives - -### **Accessibility** -- **Screen Reader Support**: Comprehensive accessibility features -- **High Contrast Mode**: Enhanced visibility options -- **Touch-Friendly Interface**: Optimized for mobile devices -- **Responsive Layout**: Adapts to different screen orientations - -## ๐Ÿ”ง Technical Specifications - -### **System Requirements** -- **Minimum SDK**: Android 8.0 (API 26) -- **Target SDK**: Android 14 (API 34) -- **Architecture**: ARM, x86, ARM64 -- **Memory**: Optimized for devices with 2GB+ RAM -- **Storage**: Minimal app size with efficient data management - -### **Performance Features** -- **Native C++ Algorithms**: Maximum computational efficiency -- **Optimized WebView**: Fast HTML rendering and JavaScript execution -- **Memory Management**: Efficient resource utilization -- **Background Processing**: Non-blocking UI operations -- **Cache Optimization**: Intelligent data caching strategies - -### **Security Features** -- **Permission Management**: Minimal required permissions -- **Data Isolation**: Secure data handling -- **WebView Security**: Safe JavaScript execution -- **Input Validation**: Secure user input processing - -## ๐Ÿš€ Getting Started - -### **Installation** -1. Build the project using Android Studio or command line -2. Install the APK on your Android device -3. Grant necessary permissions (Internet, Vibration) -4. Start studying with the intuitive interface - -### **First Steps** -1. **Dashboard Overview**: Review your study statistics -2. **Module Selection**: Choose your preferred study tool -3. **Content Creation**: Start taking notes or creating flashcards -4. **Progress Tracking**: Monitor your learning journey -5. **Game Integration**: Engage with interactive learning games - -## ๐Ÿ”ฎ Future Enhancements - -### **Planned Features** -- **Cloud Synchronization**: Cross-device data sync -- **Advanced Analytics**: Machine learning-based insights -- **Social Features**: Study group collaboration -- **Content Library**: Pre-built study materials -- **Offline Mode**: Full functionality without internet - -### **Performance Improvements** -- **Enhanced Algorithms**: More sophisticated study algorithms -- **Better Caching**: Improved data retrieval performance -- **UI Optimizations**: Smoother animations and transitions -- **Memory Optimization**: Reduced resource consumption - -## ๐Ÿ“Š Performance Metrics - -### **Study Efficiency** -- **Algorithm Speed**: Sub-millisecond response times for calculations -- **Memory Usage**: Optimized for mobile devices -- **Battery Efficiency**: Minimal impact on device battery -- **Storage Optimization**: Efficient data compression and storage - -### **User Engagement** -- **Interactive Elements**: Engaging study experience -- **Progress Visualization**: Clear feedback on achievements -- **Gamification**: Rewards and achievements system -- **Personalization**: Tailored learning experience - -## ๐Ÿค Contributing - -### **Development Setup** -1. Clone the repository -2. Install Android Studio with NDK support -3. Configure CMake and NDK paths -4. Build and run the project - -### **Code Standards** -- **Kotlin**: Follow official Kotlin coding conventions -- **C++**: Use modern C++14 standards -- **Documentation**: Comprehensive code documentation -- **Testing**: Unit tests for all critical functions - -## ๐Ÿ“„ License - -This project is licensed under the Apache License 2.0 - see the [LICENSE](LICENSE) file for details. - -## ๐Ÿ™ Acknowledgments - -- **Android NDK Team**: For native development support -- **Material Design**: For UI/UX guidelines -- **Open Source Community**: For various libraries and tools -- **Study Method Researchers**: For educational algorithm insights - ---- - -**StudySuite** - Empowering learners through intelligent technology and optimized performance. diff --git a/TECHNICAL_DOCUMENTATION.md b/TECHNICAL_DOCUMENTATION.md deleted file mode 100644 index 88320ad..0000000 --- a/TECHNICAL_DOCUMENTATION.md +++ /dev/null @@ -1,484 +0,0 @@ -# StudySuite Technical Documentation - -## Table of Contents -1. [Architecture Overview](#architecture-overview) -2. [Native C++ Implementation](#native-c-implementation) -3. [Kotlin Frontend Architecture](#kotlin-frontend-architecture) -4. [WebView Integration](#webview-integration) -5. [JNI Interface](#jni-interface) -6. [Build Configuration](#build-configuration) -7. [Performance Optimization](#performance-optimization) -8. [Security Considerations](#security-considerations) -9. [Testing Strategy](#testing-strategy) -10. [Deployment Guide](#deployment-guide) - -## Architecture Overview - -### System Architecture -``` -โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” -โ”‚ Android Application โ”‚ -โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค -โ”‚ โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”‚ -โ”‚ โ”‚ Kotlin UI โ”‚ โ”‚ WebView Interface โ”‚ โ”‚ -โ”‚ โ”‚ Layer โ”‚โ—„โ”€โ”€โ–บโ”‚ (HTML/CSS/JavaScript) โ”‚ โ”‚ -โ”‚ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ โ”‚ -โ”‚ โ”‚ โ”‚ โ”‚ -โ”‚ โ–ผ โ–ผ โ”‚ -โ”‚ โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”‚ -โ”‚ โ”‚ JNI Bridge Layer โ”‚ โ”‚ -โ”‚ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ โ”‚ -โ”‚ โ”‚ โ”‚ -โ”‚ โ–ผ โ”‚ -โ”‚ โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”‚ -โ”‚ โ”‚ Native C++ Library โ”‚ โ”‚ -โ”‚ โ”‚ (Study Algorithms & Data Processing) โ”‚ โ”‚ -โ”‚ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ โ”‚ -โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ -``` - -### Component Responsibilities -- **Kotlin UI Layer**: Activity management, navigation, system integration -- **WebView Interface**: Rich content display, user interactions -- **JNI Bridge**: Communication between Kotlin and C++ -- **Native Library**: Performance-critical algorithms and data processing - -## Native C++ Implementation - -### Core Algorithms - -#### 1. Study Scoring Algorithm -```cpp -JNIEXPORT jdouble JNICALL -Java_com_studysuite_app_StudySuiteActivity_calculateStudyScore( - JNIEnv *env, jobject thiz, jdouble hours, jint tasks) { - - // Base score calculation (0-100 scale) - double baseScore = hours * 10.0; - - // Task completion bonus - double taskBonus = tasks * 2.5; - - // Consistency bonus (max 5 points) - double consistencyBonus = std::min(hours / 2.0, 5.0); - - // Calculate total score with cap at 100 - double totalScore = baseScore + taskBonus + consistencyBonus; - return std::min(totalScore, 100.0); -} -``` - -**Algorithm Features:** -- **Base Score**: 10 points per study hour -- **Task Bonus**: 2.5 points per completed task -- **Consistency Bonus**: Up to 5 points for regular study patterns -- **Score Cap**: Maximum score limited to 100 points - -#### 2. SM-2 Flashcard Algorithm -```cpp -JNIEXPORT jdouble JNICALL -Java_com_studysuite_app_StudySuiteActivity_calculateNextReviewInterval( - JNIEnv *env, jobject thiz, jint quality, jdouble interval, - jdouble easeFactor) { - - if (quality < 3) { - // Reset interval for poor performance - return 1.0; - } - - // Calculate new ease factor - double newEaseFactor = easeFactor + - (0.1 - (5.0 - quality) * (0.08 + (5.0 - quality) * 0.02)); - - // Ensure minimum ease factor - if (newEaseFactor < 1.3) { - newEaseFactor = 1.3; - } - - // Calculate new interval - double newInterval = interval * newEaseFactor; - - return newInterval; -} -``` - -**SM-2 Algorithm Features:** -- **Quality Assessment**: 1-5 scale for answer quality -- **Ease Factor**: Dynamic adjustment based on performance -- **Interval Calculation**: Exponential spacing for optimal retention -- **Reset Mechanism**: Poor performance resets to daily review - -#### 3. Study Plan Optimization -```cpp -JNIEXPORT jdouble JNICALL -Java_com_studysuite_app_StudySuiteActivity_optimizeStudyPlan( - JNIEnv *env, jobject thiz, jdoubleArray studyHours) { - - jsize length = env->GetArrayLength(studyHours); - jdouble *hours = env->GetDoubleArrayElements(studyHours, nullptr); - - // Calculate statistical measures - double totalHours = 0; - for (int i = 0; i < length; i++) { - totalHours += hours[i]; - } - - double average = totalHours / length; - double variance = 0; - - for (int i = 0; i < length; i++) { - variance += (hours[i] - average) * (hours[i] - average); - } - variance /= length; - double stdDev = sqrt(variance); - - env->ReleaseDoubleArrayElements(studyHours, hours, 0); - - // Return efficiency score (0-100) - return std::min(100.0, (100.0 - (stdDev * 10.0))); -} -``` - -**Optimization Features:** -- **Statistical Analysis**: Mean, variance, and standard deviation -- **Efficiency Scoring**: 0-100 scale based on consistency -- **Memory Management**: Proper JNI array handling -- **Performance Metrics**: Quantitative study plan assessment - -### Memory Management -- **JNI String Handling**: Proper UTF-8 string management -- **Array Management**: Safe array access and release -- **Resource Cleanup**: Automatic cleanup of native resources -- **Memory Leak Prevention**: Strict resource lifecycle management - -## Kotlin Frontend Architecture - -### Main Activity Structure -```kotlin -class StudySuiteActivity : AppCompatActivity() { - private lateinit var webView: WebView - private lateinit var bottomNav: BottomNavigationView - private lateinit var toolbar: Toolbar - - // Native method declarations - external fun initializeStudyEngine(): Boolean - external fun processStudyData(data: String): String - external fun calculateStudyScore(hours: Double, tasks: Int): Double - external fun getOptimizedRecommendations(subject: String): String -} -``` - -### Module Management System -```kotlin -private fun loadModuleInternal(module: String) { - val htmlContent = when (module) { - "notes" -> generateNotesHTML() - "flashcards" -> generateFlashcardsHTML() - "tests" -> generateTestsHTML() - "progress" -> generateProgressHTML() - "games" -> generateGamesHTML() - else -> generateDashboardHTML() - } - webView.loadDataWithBaseURL(null, htmlContent, "text/html", "UTF-8", null) -} -``` - -### JavaScript Interface Bridge -```kotlin -inner class StudyJavaScriptInterface { - @android.webkit.JavascriptInterface - fun loadModule(module: String) { - runOnUiThread { - loadModuleInternal(module) - } - } - - @android.webkit.JavascriptInterface - fun saveNote(title: String, content: String) { - runOnUiThread { - // Save note logic - android.util.Log.d("StudySuite", "Note saved: $title") - } - } -} -``` - -## WebView Integration - -### Security Configuration -```kotlin -webView.settings.apply { - javaScriptEnabled = true - domStorageEnabled = true - loadWithOverviewMode = true - useWideViewPort = true - builtInZoomControls = true - displayZoomControls = false - - // Security settings - allowFileAccess = false - allowContentAccess = false - - // Performance settings - cacheMode = android.webkit.WebSettings.LOAD_DEFAULT -} -``` - -### Custom WebView Client -```kotlin -open class StudyWebViewClient : WebViewClient() { - override fun onPageFinished(view: WebView?, url: String?) { - super.onPageFinished(view, url) - - // Inject JavaScript interface - view?.evaluateJavascript(""" - class AndroidInterface { - loadModule(module) { - console.log('Loading module: ' + module); - } - } - window.Android = new AndroidInterface(); - """.trimIndent(), null) - } -} -``` - -### HTML Content Generation -```kotlin -private fun generateDashboardHTML(): String { - return """ - - - - - - - - // ... HTML content - - - """.trimIndent() -} -``` - -## JNI Interface - -### Native Method Declarations -```kotlin -// Native methods declaration -external fun initializeStudyEngine(): Boolean -external fun processStudyData(data: String): String -external fun calculateStudyScore(hours: Double, tasks: Int): Double -external fun getOptimizedRecommendations(subject: String): String -``` - -### Library Loading -```kotlin -companion object { - init { - System.loadLibrary("studysuite") - } -} -``` - -### Error Handling -```kotlin -private fun initializeNativeEngine() { - try { - val initialized = initializeStudyEngine() - if (initialized) { - Toast.makeText(this, "Study Engine Initialized", Toast.LENGTH_SHORT).show() - } - } catch (e: UnsatisfiedLinkError) { - Toast.makeText(this, "Native library not loaded", Toast.LENGTH_LONG).show() - } -} -``` - -## Build Configuration - -### Gradle Configuration -```groovy -android { - namespace 'com.studysuite.app' - compileSdk 34 - - defaultConfig { - applicationId "com.studysuite.app" - minSdk 26 - targetSdk 34 - versionCode 1 - versionName "1.0" - - externalNativeBuild { - cmake { - cppFlags "-std=c++14" - arguments "-DANDROID_STL=c++_shared" - } - } - } - - externalNativeBuild { - cmake { - path file('CMakeLists.txt') - version '3.18.1' - } - } - - ndkVersion "25.2.9519653" -} -``` - -### CMake Configuration -```cmake -cmake_minimum_required(VERSION 3.18.1) -project("studysuite") - -# Set C++ standard -set(CMAKE_CXX_STANDARD 14) -set(CMAKE_CXX_STANDARD_REQUIRED ON) - -# Set Android-specific variables -set(CMAKE_POSITION_INDEPENDENT_CODE ON) - -# Add library -add_library(studysuite SHARED src/main/cpp/studysuite.cpp) - -# Find required libraries -find_library(log-lib log) - -# Link libraries -target_link_libraries(studysuite ${log-lib}) - -# Android-specific properties -if(ANDROID) - set_target_properties(studysuite PROPERTIES - ANDROID_STL c++_shared - ANDROID_ARM_NEON TRUE - ) - - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fPIC") - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC") - - if(CMAKE_CXX_COMPILER_ID STREQUAL "Clang") - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fno-rtti -fno-exceptions") - endif() -endif() -``` - -### Dependencies -```groovy -dependencies { - implementation 'androidx.core:core-ktx:1.8.0' - implementation 'androidx.appcompat:appcompat:1.6.0' - implementation 'com.google.android.material:material:1.8.0' - implementation 'androidx.constraintlayout:constraintlayout:2.1.3' - implementation 'androidx.webkit:webkit:1.6.0' - testImplementation 'junit:junit:4.13.2' - androidTestImplementation 'androidx.test.ext:junit:1.1.5' - androidTestImplementation 'androidx.test.espresso:espresso-core:3.5.0' -} -``` - -## Performance Optimization - -### Native Code Optimization -- **C++14 Standard**: Modern language features for better performance -- **Position Independent Code**: Optimized for Android loading -- **ARM NEON Support**: Hardware acceleration for ARM devices -- **Memory Alignment**: Optimized data structure alignment -- **Compiler Flags**: Performance-focused compilation settings - -### WebView Optimization -- **JavaScript Optimization**: Efficient JavaScript execution -- **CSS Optimization**: Optimized styling and animations -- **Memory Management**: Efficient WebView memory usage -- **Cache Strategy**: Intelligent content caching -- **Resource Loading**: Optimized resource loading patterns - -### UI Performance -- **View Binding**: Efficient view access -- **Background Processing**: Non-blocking UI operations -- **Memory Efficient**: Minimal memory footprint -- **Smooth Animations**: Hardware-accelerated animations -- **Responsive Design**: Fast response to user interactions - -## Security Considerations - -### Permission Management -```xml - - - -``` - -### WebView Security -- **JavaScript Interface**: Limited exposed methods -- **File Access**: Disabled file system access -- **Content Access**: Restricted content access -- **Input Validation**: Secure input processing -- **XSS Prevention**: Cross-site scripting protection - -### Data Security -- **Local Storage**: Secure local data storage -- **Input Sanitization**: Clean user input processing -- **Memory Protection**: Secure memory handling -- **Resource Isolation**: Isolated resource access - -## Testing Strategy - -### Unit Testing -```kotlin -@Test -fun testStudyScoreCalculation() { - val score = calculateStudyScore(5.0, 10) - assertTrue(score > 0) - assertTrue(score <= 100) -} -``` - -### Integration Testing -- **JNI Testing**: Native method integration tests -- **WebView Testing**: JavaScript interface tests -- **UI Testing**: User interface functionality tests -- **Performance Testing**: Algorithm performance tests - -### Test Coverage -- **Algorithm Testing**: All C++ algorithms tested -- **Interface Testing**: All user interfaces tested -- **Integration Testing**: Component interaction testing -- **Performance Testing**: Speed and memory usage testing - -## Deployment Guide - -### Build Process -1. **Clean Build**: Remove all build artifacts -2. **Native Compilation**: Compile C++ libraries -3. **Kotlin Compilation**: Compile Kotlin code -4. **Resource Processing**: Process Android resources -5. **APK Generation**: Create final APK package - -### Distribution -- **Debug APK**: Development and testing -- **Release APK**: Production distribution -- **Code Signing**: Secure APK signing -- **ProGuard**: Code obfuscation and optimization - -### Installation -1. **Device Preparation**: Enable developer options -2. **APK Installation**: Install via ADB or file manager -3. **Permission Granting**: Grant required permissions -4. **Verification**: Verify app functionality - ---- - -**Note**: This technical documentation provides comprehensive coverage of the StudySuite implementation. For specific implementation details, refer to the source code files. diff --git a/USER_GUIDE.md b/USER_GUIDE.md deleted file mode 100644 index 8f78ece..0000000 --- a/USER_GUIDE.md +++ /dev/null @@ -1,310 +0,0 @@ -# StudySuite User Guide - -## Welcome to StudySuite! ๐ŸŽ“ - -StudySuite is your intelligent study companion, designed to make learning more effective, engaging, and organized. This guide will walk you through all the features and help you get the most out of your study sessions. - -## ๐Ÿ“ฑ Getting Started - -### First Launch -1. **Open the App**: Tap the StudySuite icon on your device -2. **Grant Permissions**: Allow the app to access internet and vibration features -3. **Welcome Screen**: You'll see the main dashboard with your study statistics -4. **Explore Modules**: Use the bottom navigation to explore different study tools - -### Navigation Basics -- **Bottom Navigation Bar**: Quick access to all study modules -- **Module Cards**: Tap to switch between different study tools -- **Back Button**: Return to previous screens -- **Menu Button**: Access settings and sync options - -## ๐Ÿ  Dashboard Overview - -### Main Statistics -The dashboard displays your key study metrics at a glance: - -- **Hours Studied**: Total time spent studying -- **Tasks Completed**: Number of study tasks finished -- **Day Streak**: Consecutive days of study -- **Subjects**: Number of subjects you're studying - -### Quick Actions -- **Module Selection**: Tap any module card to start studying -- **Progress View**: See your recent study activity -- **Quick Stats**: Monitor your daily progress - -## ๐Ÿ“ Notes & Documents - -### Creating Notes -1. **Open Notes Module**: Tap the Notes icon in bottom navigation -2. **Enter Title**: Type a descriptive title for your note -3. **Write Content**: Use the large text area for your notes -4. **Save Note**: Tap "Save Note" to store your work - -### Note Management -- **Auto-Save**: Your notes are automatically saved as you type -- **Organized Storage**: All notes are stored locally on your device -- **Quick Access**: View all your notes in the organized list below the editor - -### Tips for Effective Note-Taking -- **Use Clear Titles**: Make it easy to find notes later -- **Organize by Topic**: Group related information together -- **Include Examples**: Add practical examples to your notes -- **Review Regularly**: Revisit notes to reinforce learning - -## ๐Ÿง  Flashcards - -### Understanding the System -StudySuite uses the proven SM-2 spaced repetition algorithm to optimize your learning: - -- **Due Today**: Cards that need review today -- **Learning**: Cards you're still mastering -- **Review**: Cards you know well, scheduled for periodic review - -### Using Flashcards -1. **Start Studying**: Tap the flashcard to begin -2. **Read Question**: Read the question or concept -3. **Think of Answer**: Try to recall the answer -4. **Tap to Reveal**: Tap the card to see the answer and hint -5. **Rate Performance**: Use the quality rating system (1-5) - -### Quality Rating System -- **5 - Perfect**: You knew the answer immediately -- **4 - Good**: You knew the answer with some effort -- **3 - Hard**: You struggled but eventually got it right -- **2 - Failed**: You got it wrong but recognized the answer -- **1 - Complete Failure**: You had no idea - -### Flashcard Statistics -- **Due Today**: Number of cards requiring immediate review -- **Learning**: Cards in the learning phase -- **Review**: Cards scheduled for future review -- **Total Cards**: Overall number of flashcards in your collection - -## ๐Ÿ“Š Practice Tests - -### Test Structure -- **Multiple Choice**: Each question has 4 possible answers -- **Progress Tracking**: Visual progress bar shows completion -- **Question Navigation**: Move between questions easily -- **Immediate Feedback**: See results after completing the test - -### Taking a Test -1. **Read Question**: Carefully read the question and all options -2. **Select Answer**: Tap your chosen answer (it will highlight) -3. **Submit Answer**: Tap "Submit Answer" to continue -4. **View Progress**: Watch the progress bar advance -5. **Complete Test**: Answer all questions to see your final score - -### Test Results -- **Score Display**: See your percentage score immediately -- **Performance Analysis**: Understand which areas need improvement -- **Review Questions**: Go back to questions you missed -- **Progress Tracking**: Monitor improvement over time - -## ๐Ÿ“ˆ Progress Analytics - -### Weekly Study Chart -The progress chart shows your study hours for each day of the week: - -- **Bar Heights**: Represent study hours for each day -- **Trend Analysis**: Identify patterns in your study habits -- **Goal Tracking**: Compare actual vs. target study hours -- **Weekly Overview**: See your entire week at a glance - -### Key Metrics -- **Weekly Goal**: Your target study hours for the week -- **Day Streak**: Consecutive days of study activity -- **Total Hours**: Cumulative study time -- **Cards Reviewed**: Number of flashcards studied - -### Understanding Your Data -- **Consistency**: Regular study patterns improve retention -- **Peak Times**: Identify when you're most productive -- **Goal Achievement**: Track progress toward study objectives -- **Improvement Areas**: Focus on weak spots in your routine - -## ๐ŸŽฎ Study Games - -### Available Games - -#### Memory Match -- **Objective**: Find matching pairs of study-related symbols -- **How to Play**: Tap cards to reveal symbols, find matching pairs -- **Learning Value**: Improves memory and concentration -- **Difficulty**: Adjusts based on your performance - -#### Quick Quiz -- **Objective**: Answer rapid-fire questions quickly -- **How to Play**: Read questions and select answers rapidly -- **Learning Value**: Builds quick thinking and knowledge recall -- **Scoring**: Points based on speed and accuracy - -#### Word Search -- **Objective**: Find hidden study-related terms -- **How to Play**: Locate words hidden in letter grids -- **Learning Value**: Improves vocabulary and pattern recognition -- **Categories**: Different subject areas available - -#### Logic Puzzles -- **Objective**: Solve brain teasers and logic problems -- **How to Play**: Use critical thinking to solve puzzles -- **Learning Value**: Develops problem-solving skills -- **Difficulty Levels**: Multiple challenge levels available - -### Game Benefits -- **Active Learning**: Engage with material in different ways -- **Memory Enhancement**: Improve retention through play -- **Motivation**: Fun way to reinforce learning -- **Skill Development**: Build various cognitive abilities - -## ๐Ÿ”ง Settings & Customization - -### App Settings -- **Theme Selection**: Choose light or dark theme -- **Notification Preferences**: Set study reminders -- **Data Management**: Backup and restore your study data -- **Privacy Settings**: Control data sharing options - -### Study Preferences -- **Study Goals**: Set daily and weekly study targets -- **Reminder Schedule**: Configure study notifications -- **Focus Mode**: Minimize distractions during study sessions -- **Progress Sharing**: Share achievements with friends - -## ๐Ÿ“Š Study Tips & Best Practices - -### Effective Study Strategies -1. **Spaced Repetition**: Use flashcards regularly for best retention -2. **Active Recall**: Test yourself instead of just re-reading -3. **Interleaving**: Mix different subjects and topics -4. **Retrieval Practice**: Practice recalling information from memory -5. **Elaboration**: Explain concepts in your own words - -### Time Management -- **Pomodoro Technique**: Study in focused 25-minute sessions -- **Regular Breaks**: Take short breaks between study sessions -- **Consistent Schedule**: Study at the same time each day -- **Goal Setting**: Set realistic, achievable study targets - -### Note-Taking Strategies -- **Cornell Method**: Divide notes into cues, notes, and summary -- **Mind Mapping**: Create visual connections between concepts -- **Outline Method**: Organize information hierarchically -- **Charting**: Use tables and diagrams for complex information - -## ๐Ÿšจ Troubleshooting - -### Common Issues - -#### App Won't Start -- **Check Permissions**: Ensure all required permissions are granted -- **Restart Device**: Try restarting your device -- **Clear Cache**: Clear app cache in device settings -- **Reinstall**: If problems persist, reinstall the app - -#### Flashcards Not Working -- **Check Data**: Ensure you have flashcards created -- **Refresh Module**: Return to dashboard and re-enter flashcards -- **Restart App**: Close and reopen the application - -#### Notes Not Saving -- **Check Storage**: Ensure device has sufficient storage space -- **Permission Issues**: Verify app has storage permissions -- **Auto-Save**: Notes should save automatically as you type - -#### Performance Issues -- **Close Other Apps**: Free up device memory -- **Restart App**: Close and reopen StudySuite -- **Check Updates**: Ensure you have the latest version - -### Getting Help -- **In-App Support**: Use the help section in settings -- **User Community**: Join online study groups -- **Feedback System**: Report issues through the app -- **Documentation**: Refer to this guide for common solutions - -## ๐Ÿ”ฎ Advanced Features - -### Data Export -- **Note Backup**: Export notes to external storage -- **Progress Reports**: Generate detailed study analytics -- **Flashcard Export**: Share flashcards with other users -- **Statistics Export**: Download your study data - -### Customization Options -- **Personal Themes**: Create custom color schemes -- **Study Reminders**: Set personalized notification schedules -- **Goal Tracking**: Customize study objectives -- **Interface Layout**: Adjust UI elements to your preference - -### Integration Features -- **Calendar Sync**: Integrate with your device calendar -- **Cloud Backup**: Sync data across multiple devices -- **Social Sharing**: Share achievements and progress -- **External Tools**: Connect with other study applications - -## ๐Ÿ“š Study Resources - -### Built-in Content -- **Sample Flashcards**: Pre-made cards for common subjects -- **Study Templates**: Ready-to-use note formats -- **Practice Questions**: Sample test questions -- **Learning Paths**: Structured study sequences - -### External Resources -- **Web Integration**: Access online study materials -- **Document Import**: Import PDFs and other documents -- **Image Support**: Add images to notes and flashcards -- **Audio Notes**: Record voice notes for auditory learners - -## ๐ŸŽฏ Success Metrics - -### Tracking Progress -- **Study Streaks**: Monitor consecutive study days -- **Score Improvements**: Track test performance over time -- **Time Efficiency**: Measure study hours vs. outcomes -- **Retention Rates**: Monitor long-term knowledge retention - -### Setting Goals -- **Daily Targets**: Set realistic daily study goals -- **Weekly Objectives**: Plan weekly learning objectives -- **Monthly Milestones**: Track long-term progress -- **Subject Mastery**: Focus on specific subject areas - -## ๐ŸŒŸ Pro Tips - -### Maximize Learning -1. **Use Multiple Modules**: Combine different study methods -2. **Regular Review**: Schedule regular review sessions -3. **Active Participation**: Engage actively with all features -4. **Track Patterns**: Monitor what works best for you -5. **Stay Consistent**: Maintain regular study habits - -### Advanced Techniques -- **Cross-Referencing**: Link related notes and concepts -- **Progressive Difficulty**: Gradually increase challenge levels -- **Peer Learning**: Study with friends using shared content -- **Reflection Time**: Review and reflect on your learning - ---- - -## ๐Ÿ“ž Support & Contact - -### Need Help? -- **In-App Help**: Access help directly from the app -- **User Guide**: Refer to this comprehensive guide -- **Community Forum**: Connect with other users -- **Feedback System**: Share your suggestions and issues - -### Stay Updated -- **App Updates**: Keep your app updated for latest features -- **Feature Announcements**: Follow official channels for news -- **User Community**: Join discussions and share experiences -- **Tutorial Videos**: Watch video guides for complex features - ---- - -**Happy Studying! ๐ŸŽ“** - -Remember, the key to successful learning is consistency and active engagement. Use StudySuite regularly, explore all its features, and find the study methods that work best for you. Your learning journey is unique, and StudySuite is here to support you every step of the way! diff --git a/build.gradle b/build.gradle deleted file mode 100644 index 59ec469..0000000 --- a/build.gradle +++ /dev/null @@ -1,6 +0,0 @@ -// Top-level build file where you can add configuration options common to all sub-projects/modules. -plugins { - id 'com.android.application' version '8.1.4' apply false - id 'com.android.library' version '8.1.4' apply false - id 'org.jetbrains.kotlin.android' version '1.9.10' apply false -} diff --git a/clean.bat b/clean.bat deleted file mode 100644 index a65ac57..0000000 --- a/clean.bat +++ /dev/null @@ -1,64 +0,0 @@ -@echo off -echo Cleaning StudySuite project... - -echo Stopping Gradle daemons... -gradlew --stop - -echo Waiting for processes to release files... -timeout /t 3 /nobreak >nul - -echo Cleaning project... -gradlew clean - -echo Cleaning build cache... -gradlew cleanBuildCache - -echo Cleaning Gradle caches (may take time due to locked files)... -if exist "%USERPROFILE%\.gradle\caches" ( - echo Attempting to clean Gradle caches... - rmdir /s /q "%USERPROFILE%\.gradle\caches" 2>nul - if exist "%USERPROFILE%\.gradle\caches" ( - echo Some Gradle cache files are locked. They will be cleaned on next restart. - ) else ( - echo Gradle caches cleaned successfully - ) -) - -echo Cleaning Android build cache... -if exist "%USERPROFILE%\.android\build-cache" ( - rmdir /s /q "%USERPROFILE%\.android\build-cache" 2>nul - echo Android build cache cleaned -) - -echo Cleaning project build directories... -if exist "build" ( - rmdir /s /q "build" 2>nul - echo Project build directory cleaned -) - -if exist "app\build" ( - rmdir /s /q "app\build" 2>nul - echo App build directory cleaned -) - -echo Cleaning IDE files... -if exist ".idea" ( - rmdir /s /q ".idea" 2>nul - echo IntelliJ IDEA files cleaned -) - -if exist ".vscode" ( - rmdir /s /q ".vscode" 2>nul - echo VS Code files cleaned -) - -if exist ".snapshots" ( - rmdir /s /q ".snapshots" 2>nul - echo Snapshot files cleaned -) - -echo. -echo Cleanup complete! Some files may remain if they are locked by running processes. -echo If you encounter build issues, restart your computer and run this script again. -echo. -pause diff --git a/clean.ps1 b/clean.ps1 deleted file mode 100644 index 7efcb9d..0000000 --- a/clean.ps1 +++ /dev/null @@ -1,87 +0,0 @@ -# StudySuite Cleanup Script for PowerShell -Write-Host "๐Ÿงน Cleaning StudySuite project..." -ForegroundColor Green - -# Stop Gradle daemons -Write-Host "Stopping Gradle daemons..." -ForegroundColor Yellow -& .\gradlew --stop - -# Wait for processes to release files -Write-Host "Waiting for processes to release files..." -ForegroundColor Yellow -Start-Sleep -Seconds 3 - -# Clean project -Write-Host "Cleaning project..." -ForegroundColor Yellow -& .\gradlew clean - -# Clean build cache -Write-Host "Cleaning build cache..." -ForegroundColor Yellow -& .\gradlew cleanBuildCache - -# Clean project build directories -Write-Host "Cleaning project build directories..." -ForegroundColor Yellow -if (Test-Path "build") { - Remove-Item -Recurse -Force "build" -ErrorAction SilentlyContinue - Write-Host "โœ“ Project build directory cleaned" -ForegroundColor Green -} - -if (Test-Path "app\build") { - Remove-Item -Recurse -Force "app\build" -ErrorAction SilentlyContinue - Write-Host "โœ“ App build directory cleaned" -ForegroundColor Green -} - -# Clean IDE files -Write-Host "Cleaning IDE files..." -ForegroundColor Yellow -if (Test-Path ".idea") { - Remove-Item -Recurse -Force ".idea" -ErrorAction SilentlyContinue - Write-Host "โœ“ IntelliJ IDEA files cleaned" -ForegroundColor Green -} - -if (Test-Path ".vscode") { - Remove-Item -Recurse -Force ".vscode" -ErrorAction SilentlyContinue - Write-Host "โœ“ VS Code files cleaned" -ForegroundColor Green -} - -if (Test-Path ".snapshots") { - Remove-Item -Recurse -Force ".snapshots" -ErrorAction SilentlyContinue - Write-Host "โœ“ Snapshot files cleaned" -ForegroundColor Green -} - -# Clean Android build cache -Write-Host "Cleaning Android build cache..." -ForegroundColor Yellow -$androidCachePath = "$env:USERPROFILE\.android\build-cache" -if (Test-Path $androidCachePath) { - Remove-Item -Recurse -Force $androidCachePath -ErrorAction SilentlyContinue - Write-Host "โœ“ Android build cache cleaned" -ForegroundColor Green -} - -# Clean Gradle caches (handle locked files gracefully) -Write-Host "Cleaning Gradle caches..." -ForegroundColor Yellow -$gradleCachePath = "$env:USERPROFILE\.gradle\caches" -if (Test-Path $gradleCachePath) { - try { - Remove-Item -Recurse -Force $gradleCachePath -ErrorAction Stop - Write-Host "โœ“ Gradle caches cleaned successfully" -ForegroundColor Green - } catch { - Write-Host "โš  Some Gradle cache files are locked. They will be cleaned on next restart." -ForegroundColor Yellow - Write-Host " Locked files: $($_.Exception.Message)" -ForegroundColor Gray - } -} - -# Clean Gradle wrapper cache -Write-Host "Cleaning Gradle wrapper cache..." -ForegroundColor Yellow -$gradleWrapperCachePath = "gradle\wrapper\dists" -if (Test-Path $gradleWrapperCachePath) { - Remove-Item -Recurse -Force $gradleWrapperCachePath -ErrorAction SilentlyContinue - Write-Host "โœ“ Gradle wrapper cache cleaned" -ForegroundColor Green -} - -# Clean temporary files -Write-Host "Cleaning temporary files..." -ForegroundColor Yellow -Get-ChildItem -Path . -Include "*.tmp", "*.log", "*.lock" -Recurse -ErrorAction SilentlyContinue | Remove-Item -Force -ErrorAction SilentlyContinue -Write-Host "โœ“ Temporary files cleaned" -ForegroundColor Green - -Write-Host "" -Write-Host "๐ŸŽ‰ Cleanup complete!" -ForegroundColor Green -Write-Host "If you encounter build issues, restart your computer and run this script again." -ForegroundColor Yellow -Write-Host "" -Read-Host "Press Enter to continue" diff --git a/gradle.properties b/gradle.properties deleted file mode 100644 index 4238de2..0000000 --- a/gradle.properties +++ /dev/null @@ -1,51 +0,0 @@ -# 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://docs.gradle.org/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 - -# AndroidX package structure to make it clearer which packages are bundled with the -# Android operating system, and which are packaged with your app's APK -# https://developer.android.com/topic/libraries/support-library/androidx-rn -android.useAndroidX=true - -# Kotlin code style for this project: "official" or "obsolete": -kotlin.code.style=official - -# Enables namespacing of each library's R class so that its R class includes only the -# resources declared in the library itself and none from the library's dependencies, -# thereby reducing the size of the R class for that library -android.nonTransitiveRClass=true - -# Enable NDK build cache -android.enableNdkBuildCache=true - -# Suppress SDK XML version warning -android.suppressUnsupportedCompileSdk=34 - -# Suppress Java source/target deprecation warning -android.javaCompile.suppressSourceTargetDeprecationWarning=true - -# Enable Gradle build cache -org.gradle.caching=true - -# Enable parallel execution -org.gradle.parallel=true - -# Disable configuration cache to avoid conflicts -org.gradle.configuration-cache=false - -# Java compatibility settings -org.gradle.java.installations.auto-detect=true - -# Disable daemon to avoid file locking issues -org.gradle.daemon=false - -# Use strict resolution strategy -org.gradle.resolutionStrategy=strict - diff --git a/gradlew b/gradlew deleted file mode 100644 index faf9300..0000000 --- a/gradlew +++ /dev/null @@ -1,251 +0,0 @@ -#!/bin/sh - -# -# Copyright ยฉ 2015-2021 the original authors. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# -# SPDX-License-Identifier: Apache-2.0 -# - -############################################################################## -# -# Gradle start up script for POSIX generated by Gradle. -# -# Important for running: -# -# (1) You need a POSIX-compliant shell to run this script. If your /bin/sh is -# noncompliant, but you have some other compliant shell such as ksh or -# bash, then to run this script, type that shell name before the whole -# command line, like: -# -# ksh Gradle -# -# Busybox and similar reduced shells will NOT work, because this script -# requires all of these POSIX shell features: -# * functions; -# * expansions ยซ$varยป, ยซ${var}ยป, ยซ${var:-default}ยป, ยซ${var+SET}ยป, -# ยซ${var#prefix}ยป, ยซ${var%suffix}ยป, and ยซ$( cmd )ยป; -# * compound commands having a testable exit status, especially ยซcaseยป; -# * various built-in commands including ยซcommandยป, ยซsetยป, and ยซulimitยป. -# -# Important for patching: -# -# (2) This script targets any POSIX shell, so it avoids extensions provided -# by Bash, Ksh, etc; in particular arrays are avoided. -# -# The "traditional" practice of packing multiple parameters into a -# space-separated string is a well documented source of bugs and security -# problems, so this is (mostly) avoided, by progressively accumulating -# options in "$@", and eventually passing that to Java. -# -# Where the inherited environment variables (DEFAULT_JVM_OPTS, JAVA_OPTS, -# and GRADLE_OPTS) rely on word-splitting, this is performed explicitly; -# see the in-line comments for details. -# -# There are tweaks for specific operating systems such as AIX, CygWin, -# Darwin, MinGW, and NonStop. -# -# (3) This script is generated from the Groovy template -# https://github.com/gradle/gradle/blob/HEAD/platforms/jvm/plugins-application/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt -# within the Gradle project. -# -# You can find Gradle at https://github.com/gradle/gradle/. -# -############################################################################## - -# Attempt to set APP_HOME - -# Resolve links: $0 may be a link -app_path=$0 - -# Need this for daisy-chained symlinks. -while - APP_HOME=${app_path%"${app_path##*/}"} # leaves a trailing /; empty if no leading path - [ -h "$app_path" ] -do - ls=$( ls -ld "$app_path" ) - link=${ls#*' -> '} - case $link in #( - /*) app_path=$link ;; #( - *) app_path=$APP_HOME$link ;; - esac -done - -# This is normally unused -# shellcheck disable=SC2034 -APP_BASE_NAME=${0##*/} -# Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036) -APP_HOME=$( cd -P "${APP_HOME:-./}" > /dev/null && printf '%s\n' "$PWD" ) || exit - -# Use the maximum available, or set MAX_FD != -1 to use that value. -MAX_FD=maximum - -warn () { - echo "$*" -} >&2 - -die () { - echo - echo "$*" - echo - exit 1 -} >&2 - -# OS specific support (must be 'true' or 'false'). -cygwin=false -msys=false -darwin=false -nonstop=false -case "$( uname )" in #( - CYGWIN* ) cygwin=true ;; #( - Darwin* ) darwin=true ;; #( - MSYS* | MINGW* ) msys=true ;; #( - NONSTOP* ) nonstop=true ;; -esac - -CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar - - -# Determine the Java command to use to start the JVM. -if [ -n "$JAVA_HOME" ] ; then - if [ -x "$JAVA_HOME/jre/sh/java" ] ; then - # IBM's JDK on AIX uses strange locations for the executables - JAVACMD=$JAVA_HOME/jre/sh/java - else - JAVACMD=$JAVA_HOME/bin/java - fi - if [ ! -x "$JAVACMD" ] ; then - die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME - -Please set the JAVA_HOME variable in your environment to match the -location of your Java installation." - fi -else - JAVACMD=java - if ! command -v java >/dev/null 2>&1 - then - die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. - -Please set the JAVA_HOME variable in your environment to match the -location of your Java installation." - fi -fi - -# Increase the maximum file descriptors if we can. -if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then - case $MAX_FD in #( - max*) - # In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked. - # shellcheck disable=SC2039,SC3045 - MAX_FD=$( ulimit -H -n ) || - warn "Could not query maximum file descriptor limit" - esac - case $MAX_FD in #( - '' | soft) :;; #( - *) - # In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked. - # shellcheck disable=SC2039,SC3045 - ulimit -n "$MAX_FD" || - warn "Could not set maximum file descriptor limit to $MAX_FD" - esac -fi - -# Collect all arguments for the java command, stacking in reverse order: -# * args from the command line -# * the main class name -# * -classpath -# * -D...appname settings -# * --module-path (only if needed) -# * DEFAULT_JVM_OPTS, JAVA_OPTS, and GRADLE_OPTS environment variables. - -# For Cygwin or MSYS, switch paths to Windows format before running java -if "$cygwin" || "$msys" ; then - APP_HOME=$( cygpath --path --mixed "$APP_HOME" ) - CLASSPATH=$( cygpath --path --mixed "$CLASSPATH" ) - - JAVACMD=$( cygpath --unix "$JAVACMD" ) - - # Now convert the arguments - kludge to limit ourselves to /bin/sh - for arg do - if - case $arg in #( - -*) false ;; # don't mess with options #( - /?*) t=${arg#/} t=/${t%%/*} # looks like a POSIX filepath - [ -e "$t" ] ;; #( - *) false ;; - esac - then - arg=$( cygpath --path --ignore --mixed "$arg" ) - fi - # Roll the args list around exactly as many times as the number of - # args, so each arg winds up back in the position where it started, but - # possibly modified. - # - # NB: a `for` loop captures its iteration list before it begins, so - # changing the positional parameters here affects neither the number of - # iterations, nor the values presented in `arg`. - shift # remove old arg - set -- "$@" "$arg" # push replacement arg - done -fi - - -# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. -DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"' - -# Collect all arguments for the java command: -# * DEFAULT_JVM_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments, -# and any embedded shellness will be escaped. -# * For example: A user cannot expect ${Hostname} to be expanded, as it is an environment variable and will be -# treated as '${Hostname}' itself on the command line. - -set -- \ - "-Dorg.gradle.appname=$APP_BASE_NAME" \ - -classpath "$CLASSPATH" \ - org.gradle.wrapper.GradleWrapperMain \ - "$@" - -# Stop when "xargs" is not available. -if ! command -v xargs >/dev/null 2>&1 -then - die "xargs is not available" -fi - -# Use "xargs" to parse quoted args. -# -# With -n1 it outputs one arg per line, with the quotes and backslashes removed. -# -# In Bash we could simply go: -# -# readarray ARGS < <( xargs -n1 <<<"$var" ) && -# set -- "${ARGS[@]}" "$@" -# -# but POSIX shell has neither arrays nor command substitution, so instead we -# post-process each arg (as a line of input to sed) to backslash-escape any -# character that might be a shell metacharacter, then use eval to reverse -# that process (while maintaining the separation between arguments), and wrap -# the whole thing up as a single "set" statement. -# -# This will of course break if any of these variables contains a newline or -# an unmatched quote. -# - -eval "set -- $( - printf '%s\n' "$DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS" | - xargs -n1 | - sed ' s~[^-[:alnum:]+,./:=@_]~\\&~g; ' | - tr '\n' ' ' - )" '"$@"' - -exec "$JAVACMD" "$@" diff --git a/gradlew.bat b/gradlew.bat deleted file mode 100644 index 9b42019..0000000 --- a/gradlew.bat +++ /dev/null @@ -1,94 +0,0 @@ -@rem -@rem Copyright 2015 the original author or authors. -@rem -@rem Licensed under the Apache License, Version 2.0 (the "License"); -@rem you may not use this file except in compliance with the License. -@rem You may obtain a copy of the License at -@rem -@rem https://www.apache.org/licenses/LICENSE-2.0 -@rem -@rem Unless required by applicable law or agreed to in writing, software -@rem distributed under the License is distributed on an "AS IS" BASIS, -@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -@rem See the License for the specific language governing permissions and -@rem limitations under the License. -@rem -@rem SPDX-License-Identifier: Apache-2.0 -@rem - -@if "%DEBUG%"=="" @echo off -@rem ########################################################################## -@rem -@rem Gradle startup script for Windows -@rem -@rem ########################################################################## - -@rem Set local scope for the variables with windows NT shell -if "%OS%"=="Windows_NT" setlocal - -set DIRNAME=%~dp0 -if "%DIRNAME%"=="" set DIRNAME=. -@rem This is normally unused -set APP_BASE_NAME=%~n0 -set APP_HOME=%DIRNAME% - -@rem Resolve any "." and ".." in APP_HOME to make it shorter. -for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi - -@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. -set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m" - -@rem Find java.exe -if defined JAVA_HOME goto findJavaFromJavaHome - -set JAVA_EXE=java.exe -%JAVA_EXE% -version >NUL 2>&1 -if %ERRORLEVEL% equ 0 goto execute - -echo. 1>&2 -echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 1>&2 -echo. 1>&2 -echo Please set the JAVA_HOME variable in your environment to match the 1>&2 -echo location of your Java installation. 1>&2 - -goto fail - -:findJavaFromJavaHome -set JAVA_HOME=%JAVA_HOME:"=% -set JAVA_EXE=%JAVA_HOME%/bin/java.exe - -if exist "%JAVA_EXE%" goto execute - -echo. 1>&2 -echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 1>&2 -echo. 1>&2 -echo Please set the JAVA_HOME variable in your environment to match the 1>&2 -echo location of your Java installation. 1>&2 - -goto fail - -:execute -@rem Setup the command line - -set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar - - -@rem Execute Gradle -"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %* - -:end -@rem End local scope for the variables with windows NT shell -if %ERRORLEVEL% equ 0 goto mainEnd - -:fail -rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of -rem the _cmd.exe /c_ return code! -set EXIT_CODE=%ERRORLEVEL% -if %EXIT_CODE% equ 0 set EXIT_CODE=1 -if not ""=="%GRADLE_EXIT_CONSOLE%" exit %EXIT_CODE% -exit /b %EXIT_CODE% - -:mainEnd -if "%OS%"=="Windows_NT" endlocal - -:omega diff --git a/local.properties b/local.properties deleted file mode 100644 index add8d81..0000000 --- a/local.properties +++ /dev/null @@ -1,7 +0,0 @@ -## This file must *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\:\\Users\\roman\\AppData\\Local\\Android\\Sdk \ No newline at end of file diff --git a/settings.gradle b/settings.gradle deleted file mode 100644 index 0dfabf7..0000000 --- a/settings.gradle +++ /dev/null @@ -1,17 +0,0 @@ -pluginManagement { - repositories { - google() - mavenCentral() - gradlePluginPortal() - } -} -dependencyResolutionManagement { - repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS) - repositories { - google() - mavenCentral() - } -} - -rootProject.name = "StudySuite" -include ':app'