症状
リモートリポジトリのブランチの削除を試みると fatal が発生する。
1 2 3 4 |
$ git push origin :my_branch remote: fatal: bad object 0000000000000000000000000000000000000000 To https://github.com/JaneDoe/my_repository - [deleted] my_branch |
リモートリポジトリのブランチの削除を試みると fatal が発生する。
1 2 3 4 |
$ git push origin :my_branch remote: fatal: bad object 0000000000000000000000000000000000000000 To https://github.com/JaneDoe/my_repository - [deleted] my_branch |
表示(V) ⇒ コマンド パレット…
Ctrl + Shift + P
過去の特定のコミットからブランチを作成する方法
1 |
git checkout <rev> -b <branchname> |
1 |
$ git checkout 6bf73e8 -b my_new_branch |
MS-DOS互換のショートファイル名(short filename ; SFN)/8.3形式を表示させる方法
プリプロセッサへの命令
#include
#define
#if
#ifdef
#error
#warning
#pragma
Visual Studio Code の設定ファイル "settings.json" の保存場所
1 |
C:\Users\${UserName}\AppData\Roaming\Code\User\settings.json |
1 |
$HOME/Library/Application Support/Code/User/settings.json |
1 |
$HOME/.config/Code/User/settings.json |
1 |
${workspaceFolder}/.vscode/settings.json |
Open Graph Protocol
Twitter, FacebookなどのSNSでリンクをシェアするときに、リンクのタイトルや画像(サムネイル)を伝えるためのタグ情報
定義と初期化
1 2 3 4 5 |
int x = 0; int main(void) { /* 中略 */ } |
翻訳単位外(ファイルの外)で定義したグローバル変数を参照する。メモリは割り当てない。
1 2 3 4 5 |
extern int x; int main(void) { /* 中略 */ } |
どこかに外部定義があれば外部宣言としてふるまい、なければ外部定義としてふるまう。
したがって同じ名前の仮定義が複数存在しても、ひとつのメモリ領域を参照する。
1 2 3 4 5 |
int x; int main(void) { /* 中略 */ } |
上記のソースコードだけでは『定義』であるか『宣言』であるか確定できない。
Visual Studio Code 起動(拡張機能アクティブ化)のタイミングで、C/C++ Extension がコンパイラ(cl.exe)を呼び出し、意図しない設定に変更してしまう。