Skip to content

Instantly share code, notes, and snippets.

View LemonSpike's full-sized avatar
🌋

Pranav Kasetti LemonSpike

🌋
View GitHub Profile
@LemonSpike
LemonSpike / fastlane_test.sh
Created April 21, 2022 19:35
fastlane Danger build script for WeTransfer-iOS-CI
export LANG=en_US.UTF-8
export LANGUAGE=en_US.UTF-8
export LC_ALL=en_US.UTF-8
brew install mint
bundle install
bundle exec fastlane test
@LemonSpike
LemonSpike / danger_testing.sh
Created April 21, 2022 19:33
Danger CI build script
npm install -g danger
echo $PULL_REQUEST_URL
swift build
swift run danger-swift ci
@LemonSpike
LemonSpike / danger_lint.sh
Created April 21, 2022 19:31
WeTransfer-iOS-CI Danger testing build script
npm install -g danger
echo $PULL_REQUEST_URL
swift build
cd Submodules/WeTransfer-iOS-CI
swift run danger-swift ci --cache-path ../../.build --build-path ../../.build --cwd ../../
@LemonSpike
LemonSpike / Dangerfile.swift
Created April 21, 2022 16:32
Danger Swift Config with SwiftLint and PR linting only
import Danger
import Foundation
let danger = Danger()
let editedFiles = danger.git.modifiedFiles + danger.git.createdFiles
if editedFiles.count - danger.git.deletedFiles.count > 300 {
warn("Big PR, try to keep changes smaller if you can")
}
@LemonSpike
LemonSpike / Dangerfile.swift
Created April 21, 2022 16:27
WeTransfer-iOS-CI Dangerfile
import Danger
import WeTransferPRLinter
WeTransferPRLinter.lint(swiftLintConfigsFolderPath: "BuildTools")
@LemonSpike
LemonSpike / Package.swift
Created April 21, 2022 16:18
Package configuration for Danger support
// swift-tools-version:5.5
import PackageDescription
let package = Package(
name: "ModularSlothCreator-PRLinter",
defaultLocalization: "en",
products: [
.library(name: "DangerDeps", type: .dynamic, targets: ["ModularSlothCreator-PRLinter"])
],
dependencies: [
@LemonSpike
LemonSpike / ci_site_deploy.sh
Created April 13, 2022 15:26
Git Operations for DocC Deployment
git config user.name "$DOCC_GITHUB_NAME"
git config user.email "$DOCC_GITHUB_EMAIL"
# Change the GitHub URL to your repository
git remote set-url origin https://$DOCC_GITHUB_USERNAME:$DOCC_GITHUB_API_TOKEN@github.com/theappbusiness/ModularSlothCreator/
git fetch
git stash push -u -- docs doc_archives
git checkout feature/docc-hosting
rm -rf docs doc_archives
git stash apply
git add docs doc_archives
@LemonSpike
LemonSpike / LastTest.log
Last active March 11, 2022 11:30
Swift OS Repo Build output
Start testing: Mar 11 11:19 GMT
----------------------------------------------------------
1/9 Testing: api_test
1/9 Test: api_test
Command: "/Users/pkasetti/Desktop/swift-project/build/Xcode-RelWithDebInfoAssert/cmark-macosx-x86_64/api_test/RelWithDebInfo/api_test"
Directory: /Users/pkasetti/Desktop/swift-project/build/Xcode-RelWithDebInfoAssert/cmark-macosx-x86_64/testdir
"api_test" start time: Mar 11 11:19 GMT
Output:
----------------------------------------------------------
539 tests passed, 0 failed, 0 skipped
@LemonSpike
LemonSpike / .lldbinit
Last active February 14, 2023 15:29
Xcode LLDB Snippets
command alias 🚽 expression -l objc -- (void)[CATransaction flush]
command alias porvc e -l swift -- UIApplication.shared.keyWindow?.rootViewController?.value(forKey: "_printHierarchy")