Skip to content

Instantly share code, notes, and snippets.

@iamwrm
iamwrm / markdown.md
Last active February 6, 2017 01:02
Markdown hints

local image

![avatar](/user/desktop/doge.png)

web image

![avatar](http://baidu.com/pic/doge.png)
@iamwrm
iamwrm / cpp.md
Last active February 6, 2017 01:01
vscode log of mine

Prerequisite

  • Cmake
  • vscode
  • cpptool extension
brew install cmake
@iamwrm
iamwrm / update_hombrew.md
Created January 31, 2017 08:20
homebrew

brew update brew upgrade python3 brew clean

6) Install python

brew install python --framework --universal
@iamwrm
iamwrm / centos_log.md
Last active February 3, 2017 15:08
virtualbox centos ssh macOS log

SSH to local virtual machine

  • install centos 7 minimal

  • enable network

  • exact virtual machine setting network adaptor NAT

  • Port Forwarding

Host IP: 127.0.0.1
@iamwrm
iamwrm / numpy.py
Last active December 20, 2018 10:46
python.md
np.zero((3, 5), 7)
np.full((3, 5), 7)
import numpy as np
np.add(first, second)
@iamwrm
iamwrm / emacs.md
Last active February 6, 2017 04:52
emacs hints

Keybidings

File related operations

SPC f f to find a file start from the current directory

SPC f L find the file across the whole Mac system
@iamwrm
iamwrm / 0 Linux-On-MBP-Late-2016.md
Created July 27, 2018 02:39 — forked from roadrunner2/0 Linux-On-MBP-Late-2016.md
Linux on MacBook Pro Late 2016 and Mid 2017 (with Touchbar)

Introduction

This is about documenting getting Linux running on the late 2016 and mid 2017 MPB's; the focus is mostly on the MacBookPro13,3 and MacBookPro14,3 (15inch models), but I try to make it relevant and provide information for MacBookPro13,1, MacBookPro13,2, MacBookPro14,1, and MacBookPro14,2 (13inch models) too. I'm currently using Fedora 27, but most the things should be valid for other recent distros even if the details differ. The kernel version is 4.14.x (after latest update).

The state of linux on the MBP (with particular focus on MacBookPro13,2) is also being tracked on https://github.com/Dunedan/mbp-2016-linux . And for Ubuntu users there are a couple tutorials (here and here) focused on that distro and the MacBook.

Note: For those who have followed these instructions ealier, and in particular for those who have had problems with the custom DSDT, modifying the DSDT is not necessary anymore - se

@iamwrm
iamwrm / index.md
Last active August 20, 2018 07:46
Problems to solve

Unix sockets and its programming

Since cpu and the operating system is dividing the clock cycle to multiple devices, how to make the sound seems continuous?

Maybe it's done by sending "discrete" data to the audio card, and the audio card plays it "continuously"?

@iamwrm
iamwrm / network.md
Last active August 20, 2018 07:47
doc about using linux ( as a desktop maybe?)

for scientific surfing:

instsall shadowsocks-libev config it to run on 127.0.0.1:1080

however, with firefox, i could still only go on the sites that are not blocked, though I make sure that my ip is outside the greatwall. I contribute this problem to DNS pollution. For the log of sslocal shows that google.com is redirected to 0.0.0.0. With chrome, this problem never happens. Maybe chrome has some dns resolver overiding?

@iamwrm
iamwrm / main.tex
Last active December 7, 2018 03:36
Latex userful sripts
Insert pictures
\begin{figure}[H]
\centering
\includegraphics[width=1\textwidth]{m32ce}
\end{figure}