Skip to content

Instantly share code, notes, and snippets.

View gongzhang's full-sized avatar

Gong Zhang gongzhang

View GitHub Profile
@gongzhang
gongzhang / redmine-docker-compose.md
Last active July 29, 2018 04:51
Redmine Docker Compose File

Redmine+MySQL Docker Compose File

File Name: docker-compose.yml

version: '3'

services:
  redmine:
 image: redmine
@gongzhang
gongzhang / multi-service-docker-container-script.md
Last active July 29, 2018 04:53
Multi-Service Container Start-Up Script Template

Multi-Service Container Start-Up Script Template

#!/bin/bash

# Multi-Service Container Start-Up Script Template
#   https://docs.docker.com/config/containers/multi-service_container/

# Start the first process
echo "starting process 1 in screen 'p1'..."
on run {input, parameters}
(* Your script goes here *)
tell application "System Events"
tell appearance preferences
set dark mode to not dark mode
end tell
end tell
return input
import SwiftUI
import PlaygroundSupport
/// `InlineModifier` helps you apply a view modifier in a inline block.
public struct InlineModifier<R: View>: ViewModifier {
private let block: (Content) -> R
public init(@ViewBuilder _ block: @escaping (Content) -> R) {
#!/bin/sh
set -e
# 查杀/恢复 CleanMyMac 的流氓后台 HealthMonitor
#
# - 执行脚本后,原 HealthMonitor.app 会被备份并被空目录替代,然后杀掉后台进程(你直接杀是杀不净的)。此时 CleanMyMac 主应用也不能运行。
# - 再次执行脚本,则将备份的文件恢复回去,CleanMyMac 则可以正常使用。
#
# NOTE: 如果不是 Setapp 版本,进程名可能不同,需要自行修改下面变量: