This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
BOOTED_SIM_UUID=$(xcrun simctl list | grep 'Booted' | grep -o -E '[0-9A-Fa-f]{8}-([0-9A-Fa-f]{4}-){3}[0-9A-Fa-f]{12}' | head -1) | |
echo 'Path to the booted iOS Simulator storage' | |
echo ~/Library/Developer/CoreSimulator/Devices/$BOOTED_SIM_UUID |
git submodule deinit <path_to_submodule>
git rm <path_to_submodule>
git commit-m "Remove submodule"
rm -rf .git/modules/
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'dart:math'; | |
class PoliceException implements Exception { | |
PoliceException({this.msg}); | |
final String msg; | |
@override | |
String toString() => 'Police Raid {$msg}'; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'dart:math' as math; | |
Transform.rotate( | |
angle: -math.pi / 2, | |
child: Material( | |
shape: ContinuousRectangleBorder( | |
side: BorderSide(width: 2.0, color: Colors.red), | |
borderRadius: BorderRadius.circular(4.0), | |
), | |
child: Padding( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'dart:math'; | |
/** | |
* A `factory function` is a function that returns an instance of a class. | |
* Dart provides `factory` keyword to label a default or named constructor. | |
* Then it becomes our responsibility to return an instance from this constructor. | |
* | |
* A factor constructor is generally used to control the instance creation. | |
* For example, we can cache an instance of the class and return the same instance | |
* when a user is trying to create new object. |
In your local clone of your forked repository, you can add the original GitHub repository as a "remote". ("Remotes" are like nicknames for the URLs of repositories - origin is one, for example.) Then you can fetch all the branches from that upstream repository, and rebase your work to continue working on the upstream version. In terms of commands that might look like:
git remote add upstream https://github.com/whoever/whatever.git
git fetch upstream
NewerOlder