Skip to content

Instantly share code, notes, and snippets.

@jhaubrich
jhaubrich / arch_macbook.md
Last active November 28, 2021 22:53
(historic) Arch Linux on a MacBookPro 11,3 on 2015-03-05 with kernel 3.18.6-1-ARCH

Arch Linux on a MacBookPro 11,3

Read The Arch Way, fall in love you lose.

TODO

I can't believe how smoothly this went...

  • suspend - seems to work after installing gnome, pm-suspend works too... I have my eye on you. <.<
    • systemctl suspend works, but doesn't wake properly.
  • power management
@rindeal
rindeal / cpuid-dump.c
Last active December 26, 2024 16:58
CPUID dumper
#if !defined(__GNUC__) || ((__GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__) < 40800)
# error "This program requires GNU C compiler v4.8+!"
#endif
#include <stdio.h>
#include <stdbool.h>
#define PRINT_TEST_CPU_SUPPORT_RESULT(inst) printf("\t%-7s: %d\n", inst, __builtin_cpu_supports(inst)?1:0)
#define PRINT_TEST_CPU_TYPE_RESULT(inst) printf("\t%-12s: %d\n", inst, __builtin_cpu_is(inst)?1:0)
@rtrouton
rtrouton / gist:6552a3010931f7a5b5ae
Created May 11, 2015 12:57
Script to install the latest available version of Adobe Flash for OS X. Includes check of the Developer ID Installer certificate to verify it was signed by Adobe.
#!/bin/bash
# This script downloads and installs the latest Flash player for compatible Macs
# Determine OS version
osvers=$(sw_vers -productVersion | awk -F. '{print $2}')
# Determine current major version of Adobe Flash for use
# with the fileURL variable
@jhaubrich
jhaubrich / Arch Linux on a macbook.org
Last active October 30, 2025 16:14
Arch Linux on my MacBook 11,3

Arch Linux on a MacBookPro 11,3

Read The Arch Way, fall in.

Still Todo

I can’t believe how smoothly this went…

  • suspend - seems to work after installing gnome, pm-suspend works too… I have my eye on you. <.<
    • systemctl suspend works, but doesn’t wake properly.
  • power management
  • trackpad
@nuomi1
nuomi1 / PrintBootCampESDInfo.swift
Last active February 24, 2026 06:32
macOS and BootCamp Latest
#!/usr/bin/env swift
//
// PrintBootCampESDInfo.swift
//
// Created by nuomi1 on 8/5/18.
// Copyright © 2018年 nuomi1. All rights reserved.
//
import Foundation
@andromedarabbit
andromedarabbit / create-bootable-mavericks.sh
Created February 6, 2016 14:58
Create bootable Mavericks ISO
#!/usr/bin/env bash -x
hdiutil attach /Applications/Install\ OS\ X\ Mavericks.app/Contents/SharedSupport/InstallESD.dmg -noverify -nobrowse -mountpoint /Volumes/install_app
exitStatus=$?
if [ $exitStatus -ne 0 ]; then
exit $exitStatus
fi
# Convert the boot image to a sparse bundle
hdiutil convert /Volumes/install_app/BaseSystem.dmg -format UDSP -o /tmp/Mavericks

The current kernel/drivers of Fedora 24 do not support the Wifi chip used on my Mac Book Pro. Proprietary Broadcom drivers are packaged and available in the rpmfusion repo.

Verify that your card is a Broadcom using: lspci -vnn -d 14e4:

Sample output:

02:00.0 Network controller [0280]: Broadcom Corporation BCM4360 802.11ac Wireless Network Adapter [14e4:43a0] (rev 03)

Install

Install the rpmfusion repo, note only "nonfree" is required, as the Broadcom Driver is proprietry: http://rpmfusion.org/

@DianaEromosele
DianaEromosele / Change "origin" of your GIT repository
Created August 7, 2016 00:31
Change "origin" of your GIT repository
$ git remote rm origin
$ git remote add origin git@github.com:aplikacjainfo/proj1.git
$ git config master.remote origin
$ git config master.merge refs/heads/master
@yancyn
yancyn / git-svn.md
Last active January 8, 2026 00:25
Migrate Archive Google Code SVN to Git

Migrate Archive Google Code SVN to Git

Requirements

  • git
  • git-svn

Setup¹

$ sudo apt-get install git
$ sudo add-apt-repository ppa:git-core/ppa