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
release: SnapCAD Studio 1.0.10 (desktop menuler, macOS kisayollari, YakNet SSO)
Build and Push Docker Images / build (push) Canceled after 0s
Desktop Release / Build linux desktop (push) Canceled after 0s
Desktop Release / Build windows desktop (push) Canceled after 0s
Desktop Release / Attach packages to release (push) Canceled after 0s
Desktop Release / Build macos desktop (push) Canceled after 0s
CI / Typecheck and unit tests (push) Canceled after 0s
Build and Push Docker Images / build (push) Canceled after 0s
Desktop Release / Build linux desktop (push) Canceled after 0s
Desktop Release / Build windows desktop (push) Canceled after 0s
Desktop Release / Attach packages to release (push) Canceled after 0s
Desktop Release / Build macos desktop (push) Canceled after 0s
CI / Typecheck and unit tests (push) Canceled after 0s
This commit is contained in:
+13
-11
@@ -35,22 +35,24 @@ async function runAudit() {
|
||||
console.log("▶ BÖLÜM 1: 2B CAD VE POLİGON MOTORU DOĞRULAMASI");
|
||||
console.log("--------------------------------------------------------------------------------");
|
||||
|
||||
// Test 1.1: 2D Poligon Kırpma (Union & Difference)
|
||||
const polygonClipping = (await import("polygon-clipping")).default;
|
||||
const squareA = [[[0, 0], [50, 0], [50, 50], [0, 50], [0, 0]]];
|
||||
const squareB = [[[25, 25], [75, 25], [75, 75], [25, 75], [25, 25]]];
|
||||
// Test 1.1: 2D Poligon Kırpma (Union & Difference) via Clipper2
|
||||
const { Clipper, ClipType, FillRule, Point64 } = await import("clipper2-js");
|
||||
const toPath64 = (pts) => pts.map(([x, y]) => new Point64(x * 1000, y * 1000));
|
||||
const squareA = toPath64([[0, 0], [50, 0], [50, 50], [0, 50]]);
|
||||
const squareB = toPath64([[25, 25], [75, 25], [75, 75], [25, 75]]);
|
||||
|
||||
const unionResult = polygonClipping.union(squareA, squareB);
|
||||
const unionResult = Clipper.BooleanOp(ClipType.Union, [squareA], [squareB], FillRule.NonZero);
|
||||
assert(
|
||||
unionResult.length === 1 && unionResult[0][0].length >= 8,
|
||||
"İki çakışan karenin Boolean Birleşimi (Union)",
|
||||
`Tek poligon oluştu, köşe sayısı: ${unionResult[0][0].length}`
|
||||
unionResult.length === 1 && unionResult[0].length >= 8,
|
||||
"İki çakışan karenin Boolean Birleşimi (Union - Clipper2)",
|
||||
`Tek poligon oluştu, köşe sayısı: ${unionResult[0]?.length ?? 0}`
|
||||
);
|
||||
|
||||
const diffHole = polygonClipping.difference(squareA, [[[10, 10], [30, 10], [30, 30], [10, 30], [10, 10]]]);
|
||||
const holeBox = toPath64([[10, 10], [30, 10], [30, 30], [10, 30]]);
|
||||
const diffHole = Clipper.BooleanOp(ClipType.Difference, [squareA], [holeBox], FillRule.NonZero);
|
||||
assert(
|
||||
diffHole.length === 1 && diffHole[0].length === 2,
|
||||
"İç delik çıkarma Boolean Farkı (A - B)",
|
||||
diffHole.length === 2,
|
||||
"İç delik çıkarma Boolean Farkı (A - B - Clipper2)",
|
||||
`Dış kontur ve 1 adet iç delik halkası oluşturuldu`
|
||||
);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user