Skip to content

Instantly share code, notes, and snippets.

View amorenew's full-sized avatar
🎯
Focusing

Amr Abd El Wahab El Desouky amorenew

🎯
Focusing
View GitHub Profile
@amorenew
amorenew / .aliases
Created June 4, 2024 18:22
My default aliases for zsh or bash
export PATH="$PATH":"$HOME/.pub-cache/bin"
export EDITOR=nano
export VISUAL="$EDITOR"
export GPG_TTY=$(tty)
#export PATH="/Library/Frameworks/Python.framework/Versions/3.7/bin:${PATH}"
# vscode as editor
# git config --global core.editor "code --wait"
# undo it >> git config --global --unset core.editor
@amorenew
amorenew / settings.json
Created June 4, 2024 18:21
My default vscode settings in .vscode/settings.json
{
"files.autoSave": "afterDelay",
"files.autoSaveDelay": 1000,
"yaml.format.singleQuote": true,
"editor.formatOnSave": true,
"editor.foldingImportsByDefault": false,
"editor.codeActionsOnSave": {
"source.organizeImports": "explicit",
"source.fixAll": "always"
},
import React, {Component} from 'react';
import {StyleSheet, View, Text, NetInfo} from 'react-native';
import PropTypes from 'prop-types';
class InternetToast extends Component {
constructor(props) {
super(props);
this.state = {
isOnline: false
@amorenew
amorenew / Foreground.java
Created September 10, 2016 08:06 — forked from steveliles/Foreground.java
Class for detecting and eventing whether an Android app is currently foreground or background (requires API level 14+)
package com.sjl.util;
import android.app.Activity;
import android.app.Application;
import android.content.Context;
import android.os.Bundle;
import android.os.Handler;
import android.util.Log;
import java.util.List;
@amorenew
amorenew / app_.gitignore
Created February 14, 2015 21:52
Studying Time Tracker
/build