-
Notifications
You must be signed in to change notification settings - Fork 354
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
Add android support #1231
Add android support #1231
Conversation
b970b72
to
acff47f
Compare
acff47f
to
0184d63
Compare
904bbb5
to
0c90213
Compare
Ready for review : ) |
We are about to get better AVD support with android studio: NixOS/nixpkgs#315233 Edit: Howdy from nixpkgs! 👋 I was responsible for the refactor of androidenv in nixpkgs to make my life at work on a professional Android product easier. If anything is amiss, I can try to solve it. |
Hey @numinit , thanks for the information, I have been patiently following the PR. One issue that users currently face is the creation of an emulator from |
@k3yss The trick I've found is twofold: the wrapper makes new projects default their sdk.dir to the androidenv composition, but you still need the sdk.dir (and possibly ndk.dir) in your local.properties. Any new AVDs created with Android Studio work fine if this is true. |
@numinit What worked for me is:
What I wanted to ask if it was possible to do step 1 using android studio. |
It is possible to do step 1 in Android Studio. It's a little counterintuitive though, you need a project open with sdk.dir set properly for it to work right. |
@numinit I think I already have that configured, let's do a merge in the current state and wait for reviews. |
46890e3
to
bc950a6
Compare
@domenkozar can you try the flutter configuration. I have some configuration issues with home manager. |
flutter seems to be broken, investigating. |
Everything works as expected for now, hope I didn't miss something 🤞 |
5280798
to
ceb9a89
Compare
This PR adds Android support to devenv.
This integration works with the latest channel, but creating an AVD through
android studio
is not possible (Use CLI for this). To try out this PR, you need to change thedevenv
input togithub:k3yss/work/keys/android-support?dir=src/modules
in yourdevenv.yaml
file.devenv.yaml
After enabling the input, you can add
android.enable=true
in yourdevenv.nix
file.devenv.nix
You should have an base working Android environment ready.
Below are a few working screenshots:
Android Emulator working:
![image](https://private-user-images.githubusercontent.com/96657880/334353929-aeaaaadb-6cdf-4e9a-bd74-67b5f76cab76.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzkzNzQxNjUsIm5iZiI6MTczOTM3Mzg2NSwicGF0aCI6Ii85NjY1Nzg4MC8zMzQzNTM5MjktYWVhYWFhZGItNmNkZi00ZTlhLWJkNzQtNjdiNWY3NmNhYjc2LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTAyMTIlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwMjEyVDE1MjQyNVomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTczNzlmNDBjYzYzMGU4YmE2MjY5MjViODM2YzQwOWYwOGE3NWViZGQ4MmRlZmJjMzc3MDY3MTUwZmU1N2VkYzkmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.VuQWuRS229u_7qmnFj7MJAGa6SR9T_QEp5NSmX_TaUU)
React Native working:
![image](https://private-user-images.githubusercontent.com/96657880/336801229-32d7c3d7-60e1-486f-89da-f41781cc718e.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzkzNzQxNjUsIm5iZiI6MTczOTM3Mzg2NSwicGF0aCI6Ii85NjY1Nzg4MC8zMzY4MDEyMjktMzJkN2MzZDctNjBlMS00ODZmLTg5ZGEtZjQxNzgxY2M3MThlLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTAyMTIlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwMjEyVDE1MjQyNVomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWZiOTM3MjFkODYyMWUwYjFhYjBjZDExZjQ5MzJlNWI2MDYzNTFjMWI5Mzc3MTE5MDc5ZDg5MzMxMTUxZWY5YWQmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.4KGI8zD0yZn3QFQZGCrQxzCkUBKVaGjEJloYt5M_sKo)
Flutter on android working:
![image](https://private-user-images.githubusercontent.com/96657880/340977927-7d16bd88-587e-4e0f-b524-b7c929d90e9a.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzkzNzQxNjUsIm5iZiI6MTczOTM3Mzg2NSwicGF0aCI6Ii85NjY1Nzg4MC8zNDA5Nzc5MjctN2QxNmJkODgtNTg3ZS00ZTBmLWI1MjQtYjdjOTI5ZDkwZTlhLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTAyMTIlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwMjEyVDE1MjQyNVomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWU1OTcwZjZmZDhkNWE3NTZjOTRjMTkzYzVkNzYwMjM2ODM1MTNkODlkY2QyMDk3Mjc4Y2M5MWQ3NzE3MmFlMGMmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.XDsH86ri8WwIZo3kHFdDiMl4P2Ud06WjnTqDOCqkZU8)
Flutter on linux working:
![image](https://private-user-images.githubusercontent.com/96657880/336801308-d73af7aa-1572-4396-a7f3-79ac35157998.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzkzNzQxNjUsIm5iZiI6MTczOTM3Mzg2NSwicGF0aCI6Ii85NjY1Nzg4MC8zMzY4MDEzMDgtZDczYWY3YWEtMTU3Mi00Mzk2LWE3ZjMtNzlhYzM1MTU3OTk4LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTAyMTIlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwMjEyVDE1MjQyNVomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWZjZTI2ZWY2MjFlZTBjOTQ0ZTMxMTAyNDlmYjdhZTI4YTUzMDdkNjg2Y2Q1YzVjNjVmYzQ0NWY1OGZhNjI1ZjgmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.S5LsIF_A08p9wrc0tV69ZXjWnuPYpvwSGnbzUukqXc8)
TODO
Fixes #310