Skip to content

Instantly share code, notes, and snippets.

Avatar

Viktor Benei viktorbenei

  • Bitrise Ltd (CTO & Cofounder)
  • Hungary
View GitHub Profile
@shinmiy
shinmiy / bitrise_status.1m.rb
Last active Aug 11, 2021
Bitriseの状況をBitbarで表示するスクリプト | Script to show Bitrise build statuses in Bitbar
View bitrise_status.1m.rb
#!/usr/bin/ruby
require 'httpclient'
require 'json'
require 'time'
# Bitrise情報 / Bitrise Info
TOKEN = 'YOUR_TOKEN_HERE'
APPS = { 'Your App Name' => 'App Slug', 'Another App Name' => 'Another App Slug' }
@viktorbenei
viktorbenei / install-bitrise-cli.sh
Last active Jul 13, 2019
install-bitrise-cli.sh
View install-bitrise-cli.sh
#!/usr/bin/env bash
set -e
function main {
bitrise_cli_ver="$1"
if [ -z "${bitrise_cli_ver}" ] ; then
echo " [!] No version specified, required! Run this script as: $ bash install-bitrise-cli.sh x.x.x"
exit 1
fi
echo "Installing Bitrise CLI v${bitrise_cli_ver} ..."
@PillowUnicorn
PillowUnicorn / ios-bitrise.yml
Created Apr 28, 2017
Pillow's iOS bitrise.yml
View ios-bitrise.yml
---
format_version: 1.1.0
default_step_lib_source: https://github.com/bitrise-io/bitrise-steplib.git
app:
envs:
- BITRISE_PROJECT_PATH: ios/pro_mobile.xcodeproj
opts:
is_expand: false
- BITRISE_SCHEME: pro_mobile
opts:
@PillowUnicorn
PillowUnicorn / android_bitrise.yml
Created Apr 28, 2017
Pillow's Android bitrise.yml
View android_bitrise.yml
---
format_version: 1.1.0
default_step_lib_source: https://github.com/bitrise-io/bitrise-steplib.git
trigger_map:
- push_branch: qa
workflow: qa
workflows:
_init_install:
steps:
- activate-ssh-key:
View bluepill.sh
#!/bin/bash
set -ex
#install bluepill
git clone git@github.com:linkedin/bluepill.git "$BITRISE_SOURCE_DIR/bluepill"
#build bluepill
cd "$BITRISE_SOURCE_DIR/bluepill"
./scripts/bluepill.sh build
@fadookie
fadookie / bash_list_library.sh
Last active Aug 2, 2017
Example of bash array to pipe-delimited string de/serialization, for discussion at https://discuss.bitrise.io/t/output-from-multiple-instances-of-the-same-step/538
View bash_list_library.sh
# WARNING! The following is not as safe as I originally thought and I'm not sure yet the right way to do this.
# See https://unix.stackexchange.com/questions/383541/how-to-save-restore-all-shell-options-including-errexit
enable_safety() {
BITRISE_CLI_PREVIOUS_SHELL_OPTIONS=$(set +o)
set -o nounset
set -o errexit
set -o pipefail
}
View add_launchd_to_tcc.sh
#!/bin/bash
# This will add lauchd to the list of allowed processes for accessibility access
sudo sqlite3 /Library/Application\ Support/com.apple.TCC/TCC.db "INSERT or REPLACE INTO access VALUES('kTCCServiceAccessibility','/sbin/osascript',1,1,1,NULL)"
# This outputs the rows in the TCC database
sudo sqlite3 /Library/Application\ Support/com.apple.TCC/TCC.db 'select * from access'
echo "Restart is required for these changes to take effect"
@mtauraso
mtauraso / add_launchd_to_tcc.sh
Last active Feb 10, 2021
TCC Database Script
View add_launchd_to_tcc.sh
#!/bin/bash
# This will add lauchd to the list of allowed processes for accessibility access
sudo sqlite3 /Library/Application\ Support/com.apple.TCC/TCC.db "INSERT or REPLACE INTO access VALUES('kTCCServiceAccessibility','/sbin/launchd',1,1,1,NULL)"
# This outputs the rows in the TCC database
sudo sqlite3 /Library/Application\ Support/com.apple.TCC/TCC.db 'select * from access'
echo "Restart is required for these changes to take effect"
@anildigital
anildigital / gist:862675ec1b7bccabc311
Created Jul 26, 2014
Remove dangling docker images
View gist:862675ec1b7bccabc311
docker rmi $(docker images -q -f dangling=true)
@viktorbenei
viktorbenei / gist:cca967e09bf701aa9cb5
Last active Mar 19, 2018
Bash script to generate secure passwords
View gist:cca967e09bf701aa9cb5
#
# requires 'pwgen', can be installed with brew
#
# add this to your .bash_profile, .profile or .bashrc for quick terminal access
# input: the length of the password
# usage example: gensecpsw 16
# example result: XjQ%uWQ.&7-T4@`(
#
gensecpsw() {
printf '%s' $(pwgen -B -c -s -n -y $1 1) |pbcopy; echo "Has been copied to clipboard"