Skip to content

Instantly share code, notes, and snippets.

View diegorribeiro's full-sized avatar
🎯
Focusing

Diego Ribeiro diegorribeiro

🎯
Focusing
View GitHub Profile
@diegorribeiro
diegorribeiro / push.json
Created May 3, 2018 12:47
Push from postman to android devices, all apis*
{
"to":"/topics/client_android",
"notification" : {
"body" : "great match!",
"icon" : "ic_silhoette",
"color":"#99ff99",
"title": "Title"
},
"data":{ "title":"" },
"priority":"high"
@diegorribeiro
diegorribeiro / settings.json
Created May 9, 2018 13:39
Visual Code Settings => User
{
"workbench.startupEditor": "newUntitledFile",
"editor.detectIndentation": false,
"editor.tabSize": 2,
"php.validate.executablePath": "C:/xampp/php/"
}
@diegorribeiro
diegorribeiro / ionicv2_run_android.sh
Created May 15, 2018 13:40
Ionic 2 - Run android in specific target
ionic cordova run android --target 192.168.144.101:5555
@diegorribeiro
diegorribeiro / ionic-res.sh
Created June 8, 2018 00:53
Ionic v2 [cli - 3.20.0] - ionic cordova resources (returns 410 after login)
ionic config set -g backend pro
# and then
ionic login
# make your ssh key and config
# run resources again
ionic cordova resources
@diegorribeiro
diegorribeiro / setup_watchman.sh
Created July 5, 2018 14:40
How to Setup Watchman on Ubuntu 16.04
$ cd ~
$ git clone https://github.com/facebook/watchman.git
$ cd watchman/
$ git checkout v4.7.0
$ sudo apt-get install -y autoconf automake build-essential python-dev
$ ./autogen.sh
$ ./configure
$ make
$ sudo make install
@diegorribeiro
diegorribeiro / input-padding.txt
Created August 10, 2018 12:07
React-native Input default padding
In IOS the input padding works correctly, since in Android there is a
default padding and you need to set it as
==>>> paddingBottom: 0
This solves the problem of padding.
@diegorribeiro
diegorribeiro / npm-watch.sh
Created August 30, 2018 17:53
Bug: Watch mode on Linux causes a ENOSPC Node.js error
#Fixed for me
#Run this
echo fs.inotify.max_user_watches = 524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p
@diegorribeiro
diegorribeiro / release.sh
Created September 19, 2018 15:07
React native build resources for release.apk
react-native bundle \
--platform android \
--dev false \
--entry-file index.js \
--bundle-output android/app/src/main/assets/index.android.bundle \
--assets-dest android/app/src/main/res/ \
@diegorribeiro
diegorribeiro / clean-cache.sh
Last active March 26, 2024 12:24
React-native clean gradle cache
#Win
cd android && gradlew clean && cd .. && react-native run-android
#osX
cd android && bash gradlew clean && cd .. && react-native run-android
@diegorribeiro
diegorribeiro / package.json
Created October 23, 2018 13:41
Error with npm install npm ERR! Invalid version: "1.0"
{
"name": "colaboradores",
- "version": "1.7.7",
+ "version": "2.0", //"2.0" is not a valid version as defined by Semantic Versioning. Changing it to "2.0.0" should solve your issue.
"private": true,
"license": "ISC",
"scripts": {}
}