Skip to content
This repository has been archived by the owner on Sep 30, 2021. It is now read-only.

Commit

Permalink
release 4.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
kosh committed Jul 16, 2017
1 parent 7b89d1e commit 4d6ff4f
Show file tree
Hide file tree
Showing 11 changed files with 121 additions and 115 deletions.
4 changes: 2 additions & 2 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ android {
applicationId "com.fastaccess.github"
minSdkVersion 21
targetSdkVersion 26
versionCode 400
versionName "4.0.0"
versionCode 401
versionName "4.0.1"
buildConfigString "GITHUB_CLIENT_ID", (buildProperties.secrets['github_client_id'] | buildProperties.notThere['github_client_id']).string
buildConfigString "GITHUB_SECRET", (buildProperties.secrets['github_secret'] | buildProperties.notThere['github_secret']).string
buildConfigString "IMGUR_CLIENT_ID", (buildProperties.secrets['imgur_client_id'] | buildProperties.notThere['imgur_client_id']).string
Expand Down
6 changes: 1 addition & 5 deletions app/src/main/java/com/fastaccess/App.java
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
import com.crashlytics.android.Crashlytics;
import com.crashlytics.android.core.CrashlyticsCore;
import com.fastaccess.data.dao.model.Models;
import com.fastaccess.data.dao.model.PinnedRepos;
import com.fastaccess.helper.TypeFaceHelper;
import com.fastaccess.provider.colors.ColorsProvider;
import com.fastaccess.provider.emoji.EmojiManager;
Expand Down Expand Up @@ -57,9 +56,6 @@ private void init() {
Shortbread.create(this);
EmojiManager.load();
ColorsProvider.load();
if (BuildConfig.VERSION_CODE != 320) {
PinnedRepos.migrateToVersion4();
}
}

private void initFabric() {
Expand All @@ -84,7 +80,7 @@ private void setupPreference() {
public ReactiveEntityStore<Persistable> getDataStore() {
if (dataStore == null) {
EntityModel model = Models.DEFAULT;
DatabaseSource source = new DatabaseSource(this, model, "FastHub-DB", 10);
DatabaseSource source = new DatabaseSource(this, model, "FastHub-DB", 11);
Configuration configuration = source.getConfiguration();
if (BuildConfig.DEBUG) {
source.setTableCreationMode(TableCreationMode.CREATE_NOT_EXISTS);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@

@Entity @NoArgsConstructor public abstract class AbstractLogin implements Parcelable {
@Key long id;
@Column(unique = true) String login;
@Column String login;
String avatarUrl;
String gravatarId;
String url;
Expand Down Expand Up @@ -140,8 +140,7 @@ public static Observable<Boolean> onMultipleLogin(@NonNull Login userModel, bool
App.getInstance().getDataStore()
.toBlocking()
.delete(Login.class)
.where(Login.ID.eq(userModel.getId())
.or(Login.LOGIN.eq(userModel.getLogin())))
.where(Login.ID.eq(userModel.getId()))
.get()
.value();
App.getInstance().getDataStore()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@

@Entity @NoArgsConstructor public abstract class AbstractPinnedRepos implements Parcelable {
@Key @Generated long id;
@Column(unique = true) String repoFullName;
@Column(unique = false) String repoFullName;
@Convert(RepoConverter.class) Repo pinnedRepo;
@io.requery.Nullable int entryCount;
@io.requery.Nullable String login;
Expand All @@ -50,8 +50,11 @@ public static boolean pinUpin(@NonNull Repo repo) {
pinned.setRepoFullName(repo.getFullName());
pinned.setLogin(Login.getUser().getLogin());
pinned.setPinnedRepo(repo);
App.getInstance().getDataStore().toBlocking().insert(pinned);
return true;
try {
App.getInstance().getDataStore().toBlocking().insert(pinned);
return true;
} catch (Exception ignored) {}
return false;
} else {
delete(pinnedRepos.getId());
return false;
Expand All @@ -66,8 +69,9 @@ public static boolean pinUpin(@NonNull Repo repo) {
}

@Nullable public static PinnedRepos get(@NonNull String repoFullName) {
return App.getInstance().getDataStore().select(PinnedRepos.class)
.where(REPO_FULL_NAME.eq(repoFullName).and(LOGIN.eq(Login.getUser().getLogin())))
return App.getInstance().getDataStore().toBlocking().select(PinnedRepos.class)
.where(REPO_FULL_NAME.eq(repoFullName).and(LOGIN.eq(Login.getUser().getLogin()))
.or(REPO_FULL_NAME.eq(repoFullName)))
.get()
.firstOrNull();
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
package com.fastaccess.ui.adapter.viewholder

import android.annotation.SuppressLint
import android.net.Uri
import android.view.View
import android.view.ViewGroup
import com.fastaccess.R
Expand All @@ -20,9 +22,14 @@ class LoginViewHolder private constructor(itemView: View, adapter: BaseRecyclerA
val avatarLayout: AvatarLayout? by bindOptionalView(R.id.avatarLayout)
val title: FontTextView by bindView(R.id.title)

@SuppressLint("SetTextI18n")
override fun bind(login: Login) {
avatarLayout?.setUrl(login.avatarUrl, null, false, false)
title.text = login.login
title.text = if (login.isIsEnterprise) {
"${login.login} ${Uri.parse(login.enterpriseUrl).authority}"
} else {
login.login
}
}

companion object {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,6 @@ public static ProfileOrgsViewHolder newInstance(@NonNull ViewGroup parent) {

@Override public void bind(@NonNull User user) {
name.setText(user.getLogin());
avatarLayout.setUrl(user.getAvatarUrl(), user.getLogin(), true, LinkParserHelper.isEnterprise(user.getHtmlUrl()));
avatarLayout.setUrl(user.getAvatarUrl(), user.getLogin(), true, LinkParserHelper.isEnterprise(user.getUrl()));
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
android:background="?selectableItemBackground"
android:ellipsize="end"
android:maxLines="1"
android:minHeight="48dp"
android:paddingBottom="@dimen/spacing_normal"
android:paddingEnd="@dimen/spacing_xs_large"
android:paddingStart="@dimen/keyline_1"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
android:background="?selectableItemBackground"
android:ellipsize="end"
android:maxLines="1"
android:minHeight="48dp"
android:paddingBottom="@dimen/spacing_normal"
android:paddingEnd="@dimen/spacing_xs_large"
android:paddingStart="@dimen/keyline_1"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
android:background="?selectableItemBackground"
android:ellipsize="end"
android:maxLines="1"
android:minHeight="48dp"
android:paddingBottom="@dimen/spacing_normal"
android:paddingEnd="@dimen/spacing_xs_large"
android:paddingStart="@dimen/keyline_1"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
android:background="?selectableItemBackground"
android:ellipsize="end"
android:maxLines="1"
android:minHeight="48dp"
android:paddingBottom="@dimen/spacing_normal"
android:paddingEnd="@dimen/spacing_xs_large"
android:paddingStart="@dimen/keyline_1"
Expand Down
192 changes: 94 additions & 98 deletions app/src/main/res/raw/changelog.html
Original file line number Diff line number Diff line change
@@ -1,98 +1,94 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Untitled Document.md</title>
<style></style>
</head>
<body id="preview">
<h2><a id="FastHub_changelog_0"></a>FastHub changelog
</h2>
<h4><a id="Version__400_Multiple_Accounts_Enterprise__PR_changes_2"></a>Version 4.0.0 (Multiple Accounts, Enterprise &amp; PR changes)
</h4>
<blockquote>
<p>Thanks to
<a href="https://github.com/passsy">@passsy</a> &amp; his company
<a href="https://github.com/grandcentrix">@grandcentrix</a>
for providing me with an Enterprise account in their server to ease implementing Enterprise support in<strong>FastHub</strong>.
</p>
</blockquote>
<blockquote>
<p>Thanks to
<a href="https://cookicons.co">cookicons</a>
for creating
<strong>FastHub</strong>
new icon.
</p>
</blockquote>
<blockquote>
<p>Thanks to
<a href="https://github.com/dedepete">@dedepete</a>
for helping out with CI &amp; configuring nightly builds for
<strong>FastHub</strong>
</p>
</blockquote>
<h4><a id="Bugs__Enhancements__new_Features_400_10"></a>Bugs , Enhancements &amp; new Features (4.0.0)
</h4>
<ul>
<li>(New) Multiple Accounts</li>
<li>(New) Enterprise support</li>
<li>(New) PR review changes &amp; on-line-number reviews</li>
<li>(New) Support to all merge strategies (Squash &amp; Rebase)</li>
<li>(New) Comment on Commit file changes (on Code line number)</li>
<li>(New) Revamp of Branches &amp; Tags, now its easy to differentiate between them</li>
<li>(New) Clicking on multiple Commits now will ask you which one to open.</li>
<li>(New) Now you can share links to FastHub from external Apps</li>
<li>(New) Showing owner &amp; original poster in comments</li>
<li>(New) Custom code color palette</li>
<li>(New) Clicking on License should open its corresponding file</li>
<li>(New) Comment links are now copy-able thanks to (@eygraber)</li>
<li>(New) Pinned repos are now smart to sort your Pinned Repos by itself.</li>
<li>(New) Access your Repos from Menu Drawer</li>
<li>(New) Access your Starred Repos from Menu Drawer</li>
<li>(New) Showing the top most 5 accessed Pinned Repos in Menu Drawer</li>
<li>(New)
<strong>FastHub</strong>
now has Nightly builds thanks (@dedepete)
</li>
<li>(New) Disabling Issues Tab if Issues disabled in Repo.</li>
<li>(New) Added Share to Users &amp; Organizations profiles</li>
<li>(New) Czech language thanks to (@hejsekvojtech)</li>
<li>(New) Spanish language thanks to (@alete)</li>
<li>(Enhancement) Opening FastHub from other Apps should open FastHub in new document thanks to (@eygraber)</li>
<li>(Enhancement) Wiki links</li>
<li>(Enhancement) Issue &amp; PRs grammar</li>
<li>(Enhancement) Overall app layouts enhancements.</li>
<li>(Fix) Opening Submodule.</li>
<li>(Fix) Trending Language &amp; today's stars.</li>
<li>(Fix) Code wrapping.</li>
<li>(Fix) PRs/Issues where the assigned user was a Team.</li>
<li>(Fix) Added back support for Local DB in some places</li>
<li>(Fix) Added Pagination to Branches &amp; Tags.</li>
<li>(Fix) Traditional &amp; Simplified Chinese language selector.</li>
<li>(Fix) Deep markdown images relative paths.</li>
<li>(Fix) Brought back fully zoom-out in code.</li>
<li>(Fix) More deeper file links parsing</li>
<li>(Fix) First Comment edited date.</li>
<li>(Fix) All notifications refresh isn’t disappeared.</li>
<li>(Fix) Readme progressbar</li>
<li>(Fix) Some crashes from the crash report.</li>
<li>(Fix) Lots of bug fixes</li>
<li>There are more stuff are not mentioned, find them out :p</li>
</ul>
<blockquote>
<p>P.S: FastHub is still in development mode, things will eventually come, rating FastHub 1 or 5 stars in Play store to request a new
feature or to report an issue they’ll be ignored, the best place to report issues/FRs are in GitHub issue ticket, you could go to
<em>About</em> &amp; click on <em>Report Issue</em> and the issue will be posted directly to
<strong>FastHub</strong> repo.
</p>
</blockquote>
<blockquote>
<p>Thanks to everyone who contributed either via reporting bugs or via code contribution</p>
</blockquote>
<p>
<strong>Thank you very much</strong>
</p>

</body>
</html>
<h2><a id="FastHub_changelog_0"></a>FastHub changelog
</h2>
<h4><a id="Version__400_Multiple_Accounts_Enterprise__PR_changes_2"></a>Version 4.0.1 (Multiple Accounts, Enterprise &amp; PR changes)
</h4>
<blockquote>
<p>Thanks to
<a href="https://github.com/passsy">@passsy</a> &amp; his company
<a href="https://github.com/grandcentrix">@grandcentrix</a>
for providing me with an Enterprise account in their server to ease implementing Enterprise support in &nbsp; <strong>FastHub</strong>.
</p>
</blockquote>
<blockquote>
<p>Thanks to
<a href="https://cookicons.co">cookicons</a>
for creating
<strong>FastHub</strong>
new icon.
</p>
</blockquote>
<blockquote>
<p>Thanks to
<a href="https://github.com/dedepete">@dedepete</a>
for helping out with CI &amp; configuring nightly builds for
<strong>FastHub</strong>
</p>
</blockquote>
<h4><a id="Bugs__Enhancements__new_Features_400_10"></a>Bugs , Enhancements &amp; new Features (4.0.1 & 4.0.0)
</h4>
<ul>
<li>(4.0.1 Fix) Pinned repos crashes</li>
<li>(4.0.1 Fix) Multiple Accounts (if enterprise account login is same as GitHub) thanks &nbsp;
<a href="https://github.com/passsy">@passsy</a>
</li>
<li>(New) Multiple Accounts</li>
<li>(New) Enterprise support</li>
<li>(New) PR review changes &amp; on-line-number reviews</li>
<li>(New) Support to all merge strategies (Squash &amp; Rebase)</li>
<li>(New) Comment on Commit file changes (on Code line number)</li>
<li>(New) Revamp of Branches &amp; Tags, now its easy to differentiate between them</li>
<li>(New) Clicking on multiple Commits now will ask you which one to open.</li>
<li>(New) Now you can share links to FastHub from external Apps</li>
<li>(New) Showing owner &amp; original poster in comments</li>
<li>(New) Custom code color palette</li>
<li>(New) Clicking on License should open its corresponding file</li>
<li>(New) Comment links are now copy-able thanks to (@eygraber)</li>
<li>(New) Pinned repos are now smart to sort your Pinned Repos by itself.</li>
<li>(New) Access your Repos from Menu Drawer</li>
<li>(New) Access your Starred Repos from Menu Drawer</li>
<li>(New) Showing the top most 5 accessed Pinned Repos in Menu Drawer</li>
<li>(New)
<strong>FastHub</strong>
now has Nightly builds thanks (@dedepete)
</li>
<li>(New) Disabling Issues Tab if Issues disabled in Repo.</li>
<li>(New) Added Share to Users &amp; Organizations profiles</li>
<li>(New) Czech language thanks to (@hejsekvojtech)</li>
<li>(New) Spanish language thanks to (@alete)</li>
<li>(Enhancement) Opening FastHub from other Apps should open FastHub in new document thanks to (@eygraber)</li>
<li>(Enhancement) Wiki links</li>
<li>(Enhancement) Issue &amp; PRs grammar</li>
<li>(Enhancement) Overall app layouts enhancements.</li>
<li>(Fix) Opening Submodule.</li>
<li>(Fix) Trending Language &amp; today's stars.</li>
<li>(Fix) Code wrapping.</li>
<li>(Fix) PRs/Issues where the assigned user was a Team.</li>
<li>(Fix) Added back support for Local DB in some places</li>
<li>(Fix) Added Pagination to Branches &amp; Tags.</li>
<li>(Fix) Traditional &amp; Simplified Chinese language selector.</li>
<li>(Fix) Deep markdown images relative paths.</li>
<li>(Fix) Brought back fully zoom-out in code.</li>
<li>(Fix) More deeper file links parsing</li>
<li>(Fix) First Comment edited date.</li>
<li>(Fix) All notifications refresh isn’t disappeared.</li>
<li>(Fix) Readme progressbar</li>
<li>(Fix) Some crashes from the crash report.</li>
<li>(Fix) Lots of bug fixes</li>
<li>There are more stuff are not mentioned, find them out :p</li>
</ul>
<blockquote>
<p>P.S: FastHub is still in development mode, things will eventually come, rating FastHub 1 or 5 stars in Play store to request a new
feature or to report an issue they’ll be ignored, the best place to report issues/FRs are in GitHub issue ticket, you could go to
<em>About</em> &amp; click on
<em>Report Issue</em>
and the issue will be posted directly to
<strong>FastHub</strong>
repo.
</p>
</blockquote>
<blockquote>
<p>Thanks to everyone who contributed either via reporting bugs or via code contribution</p>
</blockquote>
<p>
<strong>Thank you very much</strong>
</p>

0 comments on commit 4d6ff4f

Please sign in to comment.