https://tulsi.bazel.build/docs/gettingstarted.html
brew install bazel
void disableScreenRecording({bool enabled = false}) async { | |
// Get the Android device. | |
final device = await FlutterDevice.current; | |
// Run the "adb shell settings put secure allow_screen_captures" command. | |
final result = await device.run('adb', [ | |
'shell', | |
'settings', | |
'put', | |
'secure', |
import 'dart:io'; | |
void main() { | |
// Get the current platform. | |
final platform = Platform.isAndroid ? 'android' : 'ios'; | |
// Disable remote desktop for the current platform. | |
if (platform == 'android') { | |
// Set the value of the "adb tcpip" command to 0. | |
Process.run('adb', ['tcpip', '0']); |
package main | |
import ( | |
"fmt" | |
"io/ioutil" | |
"log" | |
"net/http" | |
"github.com/gofiber/fiber/v2" | |
) |
import java.time.DayOfWeek | |
import java.time.LocalDate | |
data class Holiday( | |
val date: LocalDate, | |
val userId: Int, | |
) { | |
companion object { | |
val all = listOf( | |
Holiday(date = LocalDate.of(2023, 2, 6), userId = 1), |
import java.util.regex.Pattern | |
// How to use | |
// | |
// val actual = EmojiConverter.fromUnicode("เพชรพลอย U+1F48E 8920 เพชรพลอย U+1F48E 8920") // เพชรพลอย 💎 เพชรพลอย 💎 8920 | |
// emojiTextView.setText(EmojiCompat.get().process(actual)) | |
// | |
object EmojiConverter { | |
fun fromUnicode(textUnicode: String): String { |
if [ "${CONFIGURATION}" == "Debug-Production" ] || [ "${CONFIGURATION}" == "Release-Production" ]; | |
then | |
cp "${PROJECT_DIR}/Runner/Firebase/Production/GoogleService-Info.plist" "${PROJECT_DIR}/Runner/GoogleService-Info.plist" | |
echo "Production plist copied" | |
elif [ "${CONFIGURATION}" == "Debug-Uat" ] || [ "${CONFIGURATION}" == "Release-Uat" ]; | |
then | |
cp "${PROJECT_DIR}/Runner/Firebase/Uat/GoogleService-Info.plist" "${PROJECT_DIR}/Runner/GoogleService-Info.plist" | |
echo "Uat plist copied" |
#!/usr/bin/env bash | |
escapedPath="$(echo `pwd` | sed 's/\//\\\//g')" | |
if grep flutter pubspec.yaml > /dev/null; then | |
if [ -d "coverage" ]; then | |
# combine line coverage info from package tests to a common file | |
if [ ! -d "$MELOS_ROOT_PATH/coverage" ]; then | |
mkdir "$MELOS_ROOT_PATH/coverage" | |
fi |
# @author Pichaya Morimoto ([email protected]) | |
# How to capture Xamarin and Flutter HTTPS API traffic using iPhone and MBP | |
# วิธี mitm ดัก Web API ของ iOS App ผ่าน MacOS -> Burp Suite ที่เป็น unaware proxy | |
# (เช่น Xamarin, Flutter ที่ไม่วิ่งผ่าน System Proxy ไม่ใช้ default Cert Store ใน iPhone) | |
# ถ้าเป็นแอปปกติ ที่ใช้ system proxy อยู่แล้วไม่ต้องทำท่านี้ก็ได้ ตั้ง proxy ปกติไปได้เลย | |
1. เสียบ iPhone (ที่ jailbreak แล้ว) กับ MBP ผ่าน USB แล้วใช้ iproxy ตั้งให้ local port 8080 บน iPhone วิ่งเข้า local port 8080 บน MBP ด้วย ssh reverse tunnel (-R) | |
$ brew install usbmuxd | |
$ iproxy 2222 22 & disown && ssh -R 8080:localhost:8080 -p 2222 [email protected] -N -f |
import android.annotation.SuppressLint | |
import android.app.Activity | |
import android.graphics.Color | |
import android.view.Gravity | |
import android.view.View | |
import android.view.ViewGroup | |
import android.widget.PopupWindow | |
import android.widget.RelativeLayout | |
import android.os.Build |
https://tulsi.bazel.build/docs/gettingstarted.html
brew install bazel