sudo curl \
-L https://raw.github.com/gist/3204240/ed7e118ca6e50071576bb33be7bab3201dc38d04/kext.sh \
-o /Library/org.pqrs/PCKeyboardHack/scripts/kext.sh
This file contains 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 | |
CONFIG_DIR="lib/app/config/firebase" | |
FLAVORS=("development" "production") | |
for FLAVOR in "${FLAVORS[@]}"; do | |
PROJECT="example-prod" | |
BUNDLE_ID="com.example" | |
if [ "$FLAVOR" = "development" ]; then | |
PROJECT="example-dev" |
This file contains 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
{ | |
"Freezed model Json": { | |
"prefix": "frzjs", | |
"scope": "dart", | |
"isFileTemplate": true, | |
"body": [ | |
"import 'package:flutter/foundation.dart';", | |
"import 'package:freezed_annotation/freezed_annotation.dart';", | |
"", | |
"part '${TM_FILENAME_BASE/(.*)/${1:/lowercase}/g}.freezed.dart';", |
This file contains 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 { firestore, messaging } from 'firebase-admin'; | |
import AppDb from '../enums/app_db.enum'; | |
import { INotification } from '../interfaces/notification.interface'; | |
import { Notification } from '../models/notification/notification.model'; | |
import UserDetails from '../models/user/user_details.model'; | |
import { pathToRef } from './path_to_id'; | |
interface SendNotificationInterface | |
extends Omit<INotification, 'badge' | 'created_at' | 'notification_ref'> { |
This file contains 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
environment="default" | |
# Regex to extract the scheme name from the Build Configuration | |
# We have named our Build Configurations as Debug-dev, Debug-prod etc. | |
# Here, dev and prod are the scheme names. This kind of naming is required by Flutter for flavors to work. | |
# We are using the $CONFIGURATION variable available in the XCode build environment to extract | |
# the environment (or flavor) | |
# For eg. | |
# If CONFIGURATION="Debug-prod", then environment will get set to "prod". | |
if [[ $CONFIGURATION =~ -([^-]*)$ ]]; then |
This file contains 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
const _updateStreamFeed = async ( | |
prediction: Prediction, | |
toUpdate: Record<string, unknown>, | |
) => { | |
try { | |
const streamClient = getStreamClient(); | |
const ref: firestore.DocumentReference = prediction.ref; | |
const time = new Date().toISOString(); | |
const activity: ActivityPartialChanges<DefaultGenerics> = { | |
foreign_id: ref.id, |
This file contains 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
/// Primary key type for a Todo. | |
typedef TodoId = int; |
This file contains 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
void main() { | |
const baseUrl = 'https://weather.com'; | |
const path = '/find'; | |
final uri = Uri.parse(baseUrl + path).replace( | |
queryParameters: { | |
'key': 'value', | |
'q': 'location', | |
'aqi': 'no', | |
}, | |
); |
This file contains 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 'package:flutter/material.dart'; | |
import 'package:flutter_test/flutter_test.dart'; | |
import 'package:integration_test/integration_test.dart'; | |
import 'package:taskezdev/main.dart' as app; | |
import 'package:taskezdev/main.dart'; | |
import 'helpers.dart'; | |
void main() { |
This file contains 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
void main() { | |
List<int> array = [1,2,3]; | |
array.addAll(array); | |
print(array); | |
} |
NewerOlder