Compare commits

..

No commits in common. "5311edc4043ec820a5cee0bbd573498731c9d007" and "908f2941306fca98ff287b5f0ab4691b6423c950" have entirely different histories.

8 changed files with 35 additions and 186 deletions

View File

@ -2,7 +2,6 @@ steps:
build: build:
image: alvrme/alpine-android:android-33-jdk11 image: alvrme/alpine-android:android-33-jdk11
commands: commands:
- apk add --no-cache python3
- ./gradlew :app:assembleRelease - ./gradlew :app:assembleRelease
when: when:
path: [ app/**, build.gradle ] path: [ app/**, build.gradle ]

View File

@ -8,7 +8,6 @@ steps:
build: build:
image: alvrme/alpine-android:android-33-jdk11 image: alvrme/alpine-android:android-33-jdk11
commands: commands:
- apk add --no-cache python3
- ./gradlew :app:assembleNightly - ./gradlew :app:assembleNightly
sign: sign:
image: alvrme/alpine-android:android-33-jdk11 image: alvrme/alpine-android:android-33-jdk11

View File

@ -1,5 +1,5 @@
<h1 align="center"> <h1 align="center">
Eternity for Lemmy Eternity (formerly Infinity for Lemmy)
</h1> </h1>
<div align="center"> <div align="center">
@ -36,62 +36,24 @@ A Lemmy client for Android written in Java. It's a fork of the [Infinity for Red
--- ---
## Features ## Action Items for Eternity
Eternity is currently in the early stages of development. Expect many unfinished features and bugs! Eternity is currently in the early stages of development. Expect many unfinished features and bugs!
### Browsing Lemmy - [x] Implementation of basic post browsing feature
- [x] Support for multiple account handling
- Explore various feeds (Subscribed/Local/All) and communities - [x] Functionality for post upvotes/downvotes
- Subscribe or unsubscribe from specific communities, with the option to block - [x] Functionality to browse comments
- Discover communities federated with the current instance - [x] Capability for creating a new post
- Favorite a community for quick access - [x] Ability to create comments
- Manage your subscriptions and blocked communities - [x] Edit/Delete posts and comments
- [x] Basic inbox
### Content Engagement - [ ] Elimination of code/string references specific to Reddit
- [x] Incorporation of private messaging feature
- Engage with content by voting, saving, sharing, and creating posts or comments - [x] Feature for saving posts/comments
- Enjoy endless scrolling through feeds and posts - [x] Resolving links
- Tailor the view settings for posts (card,compact, gallery) - [ ] Account editing function
- Set default preferences for post and comment sorting - [ ] Multi community view?
- Stay updated with notifications for replies
### Account Management
- Sign in to multiple accounts or instances, and effortlessly switch between them
- Use the inbox features to view replies, mentions, and private messages
- Access your profile to view your posts, comments, and saved content
### Customization
- Choose between various theme options including Light, Dark, OLED
- Support Material You theming
- Explore user-created themes
- Customize font settings
- Optional bottom navigation bar
- Discover a plethora of other customization features
<img
src="https://codeberg.org/Bazsalanszky/Eternity/raw/branch/master/fastlane/metadata/android/en-US/images/phoneScreenshots/1.png"
alt="Screenshot 1"
height="200" >
<img
src="https://codeberg.org/Bazsalanszky/Eternity/raw/branch/master/fastlane/metadata/android/en-US/images/phoneScreenshots/2.png"
alt="Screenshot 2"
height="200" >
<img
src="https://codeberg.org/Bazsalanszky/Eternity/raw/branch/master/fastlane/metadata/android/en-US/images/phoneScreenshots/3.png"
alt="Screenshot 3"
height="200" >
<img
src="https://codeberg.org/Bazsalanszky/Eternity/raw/branch/master/fastlane/metadata/android/en-US/images/phoneScreenshots/4.png"
alt="Screenshot 4"
height="200" >
<img
src="https://codeberg.org/Bazsalanszky/Eternity/raw/branch/master/fastlane/metadata/android/en-US/images/phoneScreenshots/5.png"
alt="Screenshot 5"
height="200" >
## Contributing ## Contributing

View File

@ -98,30 +98,6 @@ android {
doNotStrip '**/*.so' doNotStrip '**/*.so'
} }
namespace 'eu.toldi.infinityforlemmy' namespace 'eu.toldi.infinityforlemmy'
task rearrangeClass(type: Exec) {
commandLine 'python', '../scripts/fixEventBus.py'
}
applicationVariants.all { variant ->
if (variant.name == 'release') {
task("compileSingleFile${variant.name.capitalize()}", type: JavaCompile, dependsOn: rearrangeClass) {
def filePath = project.rootDir.absolutePath + '/app/build/generated/ap_generated_sources/release/out/eu/toldi/infinityforlemmy/'
source = files(filePath)
includes = ["**/EventBusIndex.java"]
classpath = variant.getCompileClasspath() + files(project.rootDir.absolutePath + '/app/build/intermediates/javac/release/classes')
destinationDir = file("$buildDir/intermediates/javac/release/classes")
}
tasks.withType(JavaCompile).all { task ->
if (task.name == 'compileReleaseJavaWithJavac') {
task.finalizedBy "compileSingleFile${variant.name.capitalize()}"
}
}
}
}
} }
dependencies { dependencies {
@ -270,34 +246,3 @@ dependencies {
//debugImplementation 'com.squareup.leakcanary:leakcanary-android:x.y' //debugImplementation 'com.squareup.leakcanary:leakcanary-android:x.y'
} }
// NB: Android Studio can't find the imports; this does not affect the
// actual build since Gradle can find them just fine.
import com.android.tools.profgen.ArtProfileKt
import com.android.tools.profgen.ArtProfileSerializer
import com.android.tools.profgen.DexFile
project.afterEvaluate {
tasks.each { task ->
if (task.name.startsWith("compile") && task.name.endsWith("ReleaseArtProfile")) {
task.doLast {
outputs.files.each { file ->
if (file.name.endsWith(".profm")) {
println("Sorting ${file} ...")
def version = ArtProfileSerializer.valueOf("METADATA_0_0_2")
def profile = ArtProfileKt.ArtProfile(file)
def keys = new ArrayList(profile.profileData.keySet())
def sortedData = new LinkedHashMap()
Collections.sort keys, new DexFile.Companion()
keys.each { key -> sortedData[key] = profile.profileData[key] }
new FileOutputStream(file).with {
write(version.magicBytes$profgen)
write(version.versionBytes$profgen)
version.write$profgen(it, sortedData, "")
}
}
}
}
}
}
}

View File

@ -24,4 +24,8 @@ allprojects {
maven { url "https://jitpack.io" } maven { url "https://jitpack.io" }
jcenter() jcenter()
} }
} }
task clean(type: Delete) {
delete rootProject.buildDir
}

View File

@ -1,45 +1,17 @@
<h1>Eternity</h1> <h1>Eternity</h1>
<p>A client for Lemmy, specifically designed for Android and written in Java. This project is a fork of the Infinity for <p>A client for Lemmy, specifically designed for Android and written in Java. This project is a fork of the Infinity for Reddit project, and it is currently in the early stages of development. As such, expect many unfinished features and potential bugs!</p>
Reddit project, and it is currently in the early stages of development. As such, expect many unfinished features and
potential bugs!</p>
<h2>Features</h2> <h2>Development Progress</h2>
<p>Eternity is currently in the early stages of development. Expect many
unfinished features and bugs!</p>
<h3>Browsing Lemmy</h3>
<ul> <ul>
<li>Explore various feeds (Subscribed/Local/All) and communities</li> <li>[x] Implementation of basic post browsing feature</li>
<li>Subscribe or unsubscribe from specific communities, with the option <li>[x] Support for multiple account handling</li>
to block</li> <li>[x] Functionality for post upvotes/downvotes</li>
<li>Discover communities federated with the current instance</li> <li>[x] Functionality to browse comments</li>
<li>Favorite a community for quick access</li> <li>[ ] Capability for creating a new post</li>
<li>Manage your subscriptions and blocked communities</li> <li>[x] Ability to create comments</li>
</ul> <li>[ ] Elimination of code/string references specific to Reddit</li>
<h3>Content Engagement</h3> <li>[ ] Incorporation of private messaging feature</li>
<ul> <li>[ ] Feature for saving posts</li>
<li>Engage with content by voting, saving, sharing, and creating posts <li>[ ] Account editing function</li>
or comments</li> <li>[ ] Multi community view?</li>
<li>Enjoy endless scrolling through feeds and posts</li>
<li>Tailor the view settings for posts (card,compact, gallery)</li>
<li>Set default preferences for post and comment sorting</li>
<li>Stay updated with notifications for replies</li>
</ul>
<h3>Account Management</h3>
<ul>
<li>Sign in to multiple accounts or instances, and effortlessly switch
between them</li>
<li>Use the inbox features to view replies, mentions, and private
messages</li>
<li>Access your profile to view your posts, comments, and saved
content</li>
</ul>
<h3>Customization</h3>
<ul>
<li>Choose between various theme options including Light, Dark,
OLED</li>
<li>Support Material You theming</li>
<li>Explore user-created themes</li>
<li>Customize font settings</li>
<li>Optional bottom navigation bar</li>
<li>Discover a plethora of other customization features</li>
</ul> </ul>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 47 KiB

After

Width:  |  Height:  |  Size: 22 KiB

View File

@ -1,32 +0,0 @@
import re
import sys
def rearrange(filename):
with open(filename, 'r') as file:
content = file.read()
# Regex to find the blocks of code to rearrange
pattern = re.compile(r'(putIndex\(new SimpleSubscriberInfo\(.*?\)\);)', re.DOTALL)
blocks = pattern.findall(content)
# Sort blocks based on the class names mentioned in SimpleSubscriberInfo instances
sorted_blocks = sorted(blocks, key=lambda x: re.search(r'SimpleSubscriberInfo\((.*?),', x).group(1))
# Replace the original blocks with the sorted blocks
sorted_content = pattern.sub(lambda match: sorted_blocks.pop(0), content)
with open(filename, 'w') as file:
file.write(sorted_content)
# Project root relative to the script
project_root = __file__[:-len('/scripts/fixEventBus.py')]
path = './build/generated/ap_generated_sources/release/out/eu/toldi/infinityforlemmy/EventBusIndex.java'
# Print the path to the file to stderr
print(path, file=sys.stderr)
# Call the function with the path to EventBusIndex.java
rearrange(path)