Skip to content

Instantly share code, notes, and snippets.

View zaprogrammer's full-sized avatar
💥

Ahmed zaprogrammer

💥
View GitHub Profile
@zaprogrammer
zaprogrammer / FirebaseMessaging.dart
Created April 24, 2020 13:44
[Flutter] Firebase receive message and save it in sqflite db #flutter #dart #sqflite #firebase
//set click_action for notification and user clicks on the notification,
// data send to onLaunch method configure
final FirebaseMessaging _firebaseMessaging = FirebaseMessaging();
@override
void initState() {
prepareFirebaseCloudMessaging();
super.initState();
}
@zaprogrammer
zaprogrammer / screen_and_scale.dart
Created April 21, 2020 03:11
[Flutter snippets] Flutter useful snippets #flutter #dart
//Get screen width & height
MediaQueryData queryData = MediaQuery.of(context);
int width = queryData.size.width;
int height = queryData.size.height;
//Device pixel ratio
int ratio = queryData.devicePixelRatio;
//Get text scale factor
int textScale = queryData.textScaleFactor;
@zaprogrammer
zaprogrammer / grant-access.sh
Last active April 22, 2020 03:45
[Useful command line] Useful command lines #macos #shell
sudo chmod 042777 *
@zaprogrammer
zaprogrammer / jira.md
Last active April 22, 2020 03:47
[JIRA] Jira Filters #jira

#Filter issues waiting for Go-live: project = SAV AND (component in (Android) AND component != FIAT OR component is EMPTY) AND status = "Waiting for Go-Live" ORDER BY issuekey

@zaprogrammer
zaprogrammer / Add SSL to current terminal
Last active December 18, 2019 10:41
[Git snippets] Useful git snippets for everyday work. #Git #SSL
# List current ssl files seen to this scope
ssh-add -l
# Adds required rsa file to current terminal
ssh-add /Users/ahmedelshaabany/.ssh/id_rsa