New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
init androidenv.buildGradleApp #41855
Conversation
Some of these commits need to be reworked I think. For instance google-repository.nix should be replaced with a fetchzip call. |
export ANDROID_SDK_HOME=`pwd` | ||
|
||
mkdir -p "$ANDROID_HOME/licenses" | ||
echo -e "\n8933bad161af4178b1185d1a37fbf41ea5269c55" > "$ANDROID_HOME/licenses/android-sdk-license" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Ericson2314 Do you think this is okay to do? I guess the "assert acceptAndroidSdkLicenses" is basically covering this acceptance.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I...suppose so!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is this hash?
mv ${buildDirectory}/build/outputs/apk/*.apk $out | ||
|
||
mkdir -p $out/nix-support | ||
echo "file binary-dist \"$(echo $out/*.apk)\"" > $out/nix-support/hydra-build-products |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am actually unsure what this is doing? @Ericson2314
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't know either. @ElvishJerricco might.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No idea what this does
This is easier than having to remember which SDKs are supported, etc. Stuff based on this can become more future-proof.
As someone who helped write this stuff originally, I'm not really in favor of having this in nixpkgs in its current state. I never really considered it release quality. If possible, I'd much rather see this brought in-tree into reflex-platform. |
We can definitely look into removing this stuff but i would definitely object to adding even more android infrastructure to reflex-platform than there already is. This stuff is not specific to Reflex or even haskell so it does not seem like the right place to put it. We want more people to be using this outside of Reflex world so it gets more testing, more refactors, etc. It seems to me fairly close to doing what build-app.nix does for ant but with gradle. Maybe it makes sense to move all of this to some sort of a build support overlay or something like it though. |
I suggested reflex-platform only because I think |
Are there specific bugs or sources of instability you’re thinking of? What
features would you want it to have?
…On Thu, Jun 21, 2018 at 9:36 PM Will Fancher ***@***.***> wrote:
***@***.**** commented on this pull request.
------------------------------
In pkgs/development/mobile/androidenv/build-gradle-app.nix
<#41855 (comment)>:
> + if [ -d "$DEPENDENCIES/m2" ] ; then
+ cp -RL "$DEPENDENCIES"/m2/* .m2/repository/
+ fi
+ chmod -R 755 .m2
+ mkdir -p .m2/repository/com/android/support
+ cp -RL local_sdk/extras/android/m2repository/com/android/support/* .m2/repository/com/android/support/
+ cp -RL local_sdk/extras/google/m2repository/* .m2/repository/
+ gradle ${gradleTask} --offline --no-daemon -g ./tmp -Dmaven.repo.local=`pwd`/.m2/repository
+ '';
+
+ installPhase = ''
+ mkdir -p $out
+ mv ${buildDirectory}/build/outputs/apk/*.apk $out
+
+ mkdir -p $out/nix-support
+ echo "file binary-dist \"$(echo $out/*.apk)\"" > $out/nix-support/hydra-build-products
No idea what this does
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#41855 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AHFpRq9AMxQCxiIQfnxc59Nw6m_WHDcOks5t_EovgaJpZM4UjF43>
.
|
This PR does not have any tests to demonstrate the usability of the function "buildGradleApps". Shall we add some tests for it @matthewbauer? In addition. Note that |
This might be helpful: https://github.com/obsidiansystems/haven
…On Fri, 28 Sep 2018 22:13:42 -0700 Ding Xiang Fei ***@***.***> wrote:
This PR does not have any tests to demonstrate the usability of the function "buildGradleApps". Shall we add some tests for it?
--
You are receiving this because you were mentioned.
Reply to this email directly or view it on GitHub:
#41855 (comment)
--
Ali Abrar <aliabrar@gmail.com>
|
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: https://discourse.nixos.org/t/using-androidenv-error-functionargs-requires-a-function/32773/5 |
Motivation for this change
This is the last big piece of code that is used by reflex-platform but missing in nixpkgs. It is used to generate apps using the gradle build system.
Need feedback on whether this is useful in Nixpkgs.
/cc @ali-abrar @ryantrinkle @Ericson2314