Skip to content

Instantly share code, notes, and snippets.

View fyddaben's full-sized avatar
🎯
Focusing

daben1990 fyddaben

🎯
Focusing
View GitHub Profile
@yanyaoer
yanyaoer / 1.scribe.sh
Last active November 1, 2023 07:04
scribe.sh -- transcribe online video to subtitles
#!/usr/bin/env bash
url=$1
utc=$(date +%s)
whisper_bin=~/Projects/agi/whisper.cpp/main
whisper_model=~/projects/agi/whisper.cpp/models/ggml-large.bin
wav_file=/tmp/$utc.wav
yt-dlp $url -k -x --audio-format wav --postprocessor-args '-ar 16000 -ac 1' -o $wav_file
#ffmpeg -i "$url" -ar 16000 -ac 1 -c:a pcm_s16le $wav_file
@wxingheng
wxingheng / mac os下vscode快捷键
Created October 7, 2018 15:03
mac os下vscode快捷键
[mac os下vscode快捷键](https://www.cnblogs.com/informatics/p/8315339.html)
全局
Command + Shift + P / F1 显示命令面板
Command + P 快速打开
Command + Shift + N 打开新窗口
Command + W 关闭窗口
基本
Command + X 剪切(未选中文本的情况下,剪切光标所在行)
Command + C 复制(未选中文本的情况下,复制光标所在行)
@13122310958
13122310958 / autoplay-audio-ios.html
Created April 22, 2017 08:26 — forked from ufologist/autoplay-audio-ios.html
在 iOS 微信浏览器中自动播放 HTML5 audio(音乐) 的正确方式
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
<title>Auto play html audio in iOS WeChat InAppBrowser the right way</title>
</head>
<body>
<h1>在 iOS 微信浏览器中自动播放 HTML5 audio(音乐) 的正确方式</h1>
<p>核心原理: 在微信的JS-API 中 play 一下 audio 即可达到自动播放的目的(应该是微信自己做了处理)</p>
@jerrybendy
jerrybendy / index.html
Created January 5, 2017 03:33
一个使用 HTML5 录音的例子(网上看到的,收藏下)
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title></title>
</head>
<body>
<div>
<audio controls autoplay></audio>
<input onclick="startRecording()" type="button" value="录音" />
/**
* Default configuration to lint
* the airbnb css style-guide.
* This file is taken from a pull request to Airbnb/css repo
* which intends to create a default preset that can be used
* in the future. Until it is merged, we will have the config here.
* https://github.com/airbnb/css/pull/23
* Add more rules: http://stylelint.io/user-guide/rules/
* Also, to understand better who the rules are named:
* http://stylelint.io/user-guide/about-rules/
@kamikat
kamikat / trig.scss
Last active December 7, 2023 12:50
SCSS/SASS module calculating sin/cos/tan using Taylor Expansion.
///////////////////////////////////////////////////////////
// Plain SASS Trigonometry Algorithm in Taylor Expansion //
// //
// Based on //
// http://japborst.net/posts/sass-sines-and-cosines //
///////////////////////////////////////////////////////////
$pi: 3.14159265359;
$_precision: 10;
@codeinthehole
codeinthehole / docker-osx-shared-folders.rst
Last active November 11, 2023 01:22
How to share folders with docker containers on OSX

How to share a folder with a docker container on OSX

Mounting shared folders between OSX and the docker container is tricky due to the intermediate boot2docker VM. You can't use the usual docker -v option as the docker server knows nothing about the OSX filesystem - it can only mount folders from the boot2docker filesystem. Fortunately, you can work around this using SSHFS.

@theconektd
theconektd / github.css
Created April 30, 2012 02:11
Github Markdown CSS - for Markdown Editor Preview
body {
font-family: Helvetica, arial, sans-serif;
font-size: 14px;
line-height: 1.6;
padding-top: 10px;
padding-bottom: 10px;
background-color: white;
padding: 30px; }
body > *:first-child {
<!doctype html>
<!-- http://taylor.fausak.me/2015/01/27/ios-8-web-apps/ -->
<html>
<head>
<title>iOS 8 web app</title>
<!-- CONFIGURATION -->
@jackfuchs
jackfuchs / jquery.support.cssproperty.js
Last active January 13, 2024 16:07
Extends the jQuery.support object to CSS Properties
/**
* jQuery.support.cssProperty
* To verify that a CSS property is supported
* (or any of its browser-specific implementations)
*
* @param p css property name
* @param rp optional, if set to true, the css property name will be returned
* instead of a boolean support indicator
* @return {mixed}
*