Git Komut Rehberi & Terminal Asistanı
Sıfırdan Yeni Bir Depo Başlatın:
Mevcut Bir Git Deposu veya Klasörü Gönderin:
Hataları Geri Alma, İptal & Temizlik:
Son commit'i geri al (yapılan değişiklikleri korur):
git reset --soft HEAD~1
Yapılan yerel değişiklikleri iptal et (çalışma ağacını temizler):
git restore .
Takip edilmeyen gereksiz dosyaları sil:
git clean -fd
Değişiklikleri geçici sakla ve geri getir (stash):
git stash git stash pop
Dal (Branch) ve Sürüm Etiketleri:
Yeni dal aç ve geçiş yap:
git checkout -b yeni-ozellik git push -u origin yeni-ozellik
Sürüm etiketi (tag) oluştur ve gönder:
git tag -a v1.0.0 -m "Sürüm 1.0.0" git push origin --tags
feat: improve modeling, exports, and hosted deployment
This commit is contained in:
@@ -0,0 +1,31 @@
|
||||
import { spawn } from "node:child_process";
|
||||
|
||||
const parentPid = Number.parseInt(process.argv[2] || "", 10);
|
||||
const repoRoot = process.argv[3] || process.cwd();
|
||||
const sleep = (ms) => new Promise((resolve) => setTimeout(resolve, ms));
|
||||
|
||||
// Give the update API response time to reach the browser before stopping Next.
|
||||
await sleep(1200);
|
||||
|
||||
if (Number.isFinite(parentPid) && parentPid > 0) {
|
||||
try {
|
||||
process.kill(parentPid, "SIGTERM");
|
||||
} catch {
|
||||
// The dev server may already have stopped on its own.
|
||||
}
|
||||
}
|
||||
|
||||
await sleep(1200);
|
||||
|
||||
const options = {
|
||||
cwd: repoRoot,
|
||||
detached: true,
|
||||
stdio: "ignore",
|
||||
windowsHide: true,
|
||||
};
|
||||
|
||||
const child = process.platform === "win32"
|
||||
? spawn("cmd.exe", ["/d", "/s", "/c", "npm run dev"], options)
|
||||
: spawn("npm", ["run", "dev"], options);
|
||||
|
||||
child.unref();
|
||||
Reference in New Issue
Block a user