I'm adding alarms via AlarmManager.
Checking with this command if the alarm exist:
adb shell dumpsys alarm
After setting the alarm (repeating alarm setRepeating()), if I close the app via back button or close via task manager, the alarm is still there in the log.
But when I re-run the app (shift f10) from Android studio the alarm is not there anymore!
What am I missing?
When you re-run the app the Android studio installs the app, so you'll lose the Alarm.
The repeat alarm cancels when cancel(OnAlarmListener) is called which I guess happens when updating/re-install the app.
You may find this StackOverflow's answer useful.
Consider other ways to apply the app changes as an alternative.