clapp-pm 1.0.17__py3-none-any.whl → 1.0.19__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,361 @@
1
+ # clapp Geliştirici Rehberi
2
+
3
+ Bu rehber, clapp için uygulama geliştirmek isteyen geliştiriciler için hazırlanmıştır.
4
+
5
+ ## 📋 İçindekiler
6
+
7
+ 1. [Başlangıç](#başlangıç)
8
+ 2. [Manifest Dosyası](#manifest-dosyası)
9
+ 3. [Desteklenen Diller](#desteklenen-diller)
10
+ 4. [Uygulama Yapısı](#uygulama-yapısı)
11
+ 5. [Bağımlılık Yönetimi](#bağımlılık-yönetimi)
12
+ 6. [Test ve Doğrulama](#test-ve-doğrulama)
13
+ 7. [Yayınlama](#yayınlama)
14
+ 8. [En İyi Uygulamalar](#en-iyi-uygulamalar)
15
+
16
+ ## 🚀 Başlangıç
17
+
18
+ ### Yeni Uygulama Oluşturma
19
+
20
+ Yeni bir clapp uygulaması oluşturmak için:
21
+
22
+ ```bash
23
+ # Python uygulaması oluştur
24
+ clapp new python my-app
25
+
26
+ # Lua uygulaması oluştur
27
+ clapp new lua my-lua-app
28
+
29
+ # Diğer diller için
30
+ clapp new dart my-dart-app
31
+ clapp new go my-go-app
32
+ clapp new rust my-rust-app
33
+ ```
34
+
35
+ ### Manuel Oluşturma
36
+
37
+ Eğer `clapp new` komutu henüz mevcut değilse, manuel olarak oluşturabilirsiniz:
38
+
39
+ 1. Yeni bir klasör oluşturun
40
+ 2. `manifest.json` dosyası ekleyin
41
+ 3. Giriş dosyanızı oluşturun
42
+ 4. Gerekli dosyaları ekleyin
43
+
44
+ ## 📄 Manifest Dosyası
45
+
46
+ Her clapp uygulaması bir `manifest.json` dosyasına sahip olmalıdır.
47
+
48
+ ### Zorunlu Alanlar
49
+
50
+ ```json
51
+ {
52
+ "name": "my-app",
53
+ "version": "1.0.0",
54
+ "language": "python",
55
+ "entry": "main.py"
56
+ }
57
+ ```
58
+
59
+ ### Opsiyonel Alanlar
60
+
61
+ ```json
62
+ {
63
+ "name": "my-app",
64
+ "version": "1.0.0",
65
+ "language": "python",
66
+ "entry": "main.py",
67
+ "description": "Uygulama açıklaması",
68
+ "author": "Geliştirici Adı",
69
+ "license": "MIT",
70
+ "dependencies": ["other-app"],
71
+ "tags": ["utility", "tool"],
72
+ "category": "productivity"
73
+ }
74
+ ```
75
+
76
+ ### Alan Açıklamaları
77
+
78
+ - **name**: Uygulama adı (benzersiz olmalı)
79
+ - **version**: Sürüm numarası (semantic versioning önerilir)
80
+ - **language**: Programlama dili (python, lua, dart, go, rust, vb.)
81
+ - **entry**: Giriş dosyası (uygulamanın başlangıç noktası)
82
+ - **description**: Uygulama açıklaması
83
+ - **author**: Geliştirici bilgisi
84
+ - **license**: Lisans bilgisi
85
+ - **dependencies**: Bağımlılık listesi (diğer clapp uygulamaları)
86
+ - **tags**: Etiketler (arama için)
87
+ - **category**: Kategori (store, productivity, game, vb.)
88
+
89
+ ## 🌐 Desteklenen Diller
90
+
91
+ ### Python
92
+ - **Dosya uzantısı**: `.py`
93
+ - **Giriş noktası**: `python main.py`
94
+ - **Örnek**: `main.py`
95
+
96
+ ### Lua
97
+ - **Dosya uzantısı**: `.lua`
98
+ - **Giriş noktası**: `lua main.lua`
99
+ - **Örnek**: `main.lua`
100
+
101
+ ### Dart
102
+ - **Dosya uzantısı**: `.dart`
103
+ - **Giriş noktası**: `dart main.dart`
104
+ - **Örnek**: `main.dart`
105
+
106
+ ### Go
107
+ - **Dosya uzantısı**: `.go`
108
+ - **Giriş noktası**: `go run main.go`
109
+ - **Örnek**: `main.go`
110
+
111
+ ### Rust
112
+ - **Dosya uzantısı**: `.rs`
113
+ - **Giriş noktası**: `cargo run`
114
+ - **Örnek**: `Cargo.toml` + `src/main.rs`
115
+
116
+ ### Node.js
117
+ - **Dosya uzantısı**: `.js`
118
+ - **Giriş noktası**: `node main.js`
119
+ - **Örnek**: `main.js`
120
+
121
+ ### Bash
122
+ - **Dosya uzantısı**: `.sh`
123
+ - **Giriş noktası**: `bash main.sh`
124
+ - **Örnek**: `main.sh`
125
+
126
+ ### Perl
127
+ - **Dosya uzantısı**: `.pl`
128
+ - **Giriş noktası**: `perl main.pl`
129
+ - **Örnek**: `main.pl`
130
+
131
+ ### Ruby
132
+ - **Dosya uzantısı**: `.rb`
133
+ - **Giriş noktası**: `ruby main.rb`
134
+ - **Örnek**: `main.rb`
135
+
136
+ ### PHP
137
+ - **Dosya uzantısı**: `.php`
138
+ - **Giriş noktası**: `php main.php`
139
+ - **Örnek**: `main.php`
140
+
141
+ ## 📁 Uygulama Yapısı
142
+
143
+ ### Temel Yapı
144
+
145
+ ```
146
+ my-app/
147
+ ├── manifest.json # Zorunlu
148
+ ├── main.py # Giriş dosyası (manifest'te belirtilen)
149
+ ├── README.md # Opsiyonel
150
+ ├── requirements.txt # Python bağımlılıkları (opsiyonel)
151
+ └── assets/ # Statik dosyalar (opsiyonel)
152
+ ├── images/
153
+ └── data/
154
+ ```
155
+
156
+ ### Örnek Python Uygulaması
157
+
158
+ **manifest.json:**
159
+ ```json
160
+ {
161
+ "name": "hello-world",
162
+ "version": "1.0.0",
163
+ "language": "python",
164
+ "entry": "main.py",
165
+ "description": "Basit bir Hello World uygulaması",
166
+ "author": "Geliştirici",
167
+ "tags": ["example", "hello"]
168
+ }
169
+ ```
170
+
171
+ **main.py:**
172
+ ```python
173
+ #!/usr/bin/env python3
174
+
175
+ def main():
176
+ print("Merhaba Dünya!")
177
+ print("Bu bir clapp uygulamasıdır.")
178
+
179
+ if __name__ == "__main__":
180
+ main()
181
+ ```
182
+
183
+ ### Örnek Lua Uygulaması
184
+
185
+ **manifest.json:**
186
+ ```json
187
+ {
188
+ "name": "lua-calculator",
189
+ "version": "1.0.0",
190
+ "language": "lua",
191
+ "entry": "main.lua",
192
+ "description": "Basit hesap makinesi",
193
+ "tags": ["calculator", "math"]
194
+ }
195
+ ```
196
+
197
+ **main.lua:**
198
+ ```lua
199
+ #!/usr/bin/env lua
200
+
201
+ function main()
202
+ print("Lua Hesap Makinesi")
203
+ print("2 + 2 = " .. (2 + 2))
204
+ end
205
+
206
+ main()
207
+ ```
208
+
209
+ ## 🔗 Bağımlılık Yönetimi
210
+
211
+ ### clapp Bağımlılıkları
212
+
213
+ Manifest dosyasında diğer clapp uygulamalarını bağımlılık olarak belirtebilirsiniz:
214
+
215
+ ```json
216
+ {
217
+ "name": "my-app",
218
+ "version": "1.0.0",
219
+ "language": "python",
220
+ "entry": "main.py",
221
+ "dependencies": ["database-app", "auth-app"]
222
+ }
223
+ ```
224
+
225
+ ### Sistem Bağımlılıkları
226
+
227
+ Her dil için sistem bağımlılıkları farklı şekilde yönetilir:
228
+
229
+ #### Python
230
+ - `requirements.txt` dosyası kullanın
231
+ - `pip install -r requirements.txt` otomatik çalışır
232
+
233
+ #### Node.js
234
+ - `package.json` dosyası kullanın
235
+ - `npm install` otomatik çalışır
236
+
237
+ #### Rust
238
+ - `Cargo.toml` dosyası kullanın
239
+ - `cargo build` otomatik çalışır
240
+
241
+ ### Bağımlılık Kontrolü
242
+
243
+ ```bash
244
+ # Uygulama bağımlılıklarını kontrol et
245
+ clapp dependency check my-app
246
+
247
+ # Bağımlılık ağacını göster
248
+ clapp dependency tree my-app
249
+ ```
250
+
251
+ ## 🧪 Test ve Doğrulama
252
+
253
+ ### Uygulama Doğrulama
254
+
255
+ ```bash
256
+ # Uygulama klasörünü doğrula
257
+ clapp validate ./my-app
258
+ ```
259
+
260
+ ### Test Çalıştırma
261
+
262
+ ```bash
263
+ # Uygulamayı test et
264
+ clapp run my-app
265
+ ```
266
+
267
+ ### Bağımlılık Testi
268
+
269
+ ```bash
270
+ # Bağımlılıkları test et
271
+ clapp dependency check my-app
272
+ ```
273
+
274
+ ## 📦 Yayınlama
275
+
276
+ ### Yerel Test
277
+
278
+ ```bash
279
+ # Uygulamayı yerel olarak test et
280
+ clapp install ./my-app
281
+ clapp run my-app
282
+ ```
283
+
284
+ ### Paket Oluşturma
285
+
286
+ ```bash
287
+ # Paket oluştur
288
+ clapp publish ./my-app
289
+ ```
290
+
291
+ ### GitHub'a Yükleme
292
+
293
+ ```bash
294
+ # GitHub'a otomatik yükle
295
+ clapp publish ./my-app --push
296
+ ```
297
+
298
+ ## ✅ En İyi Uygulamalar
299
+
300
+ ### 1. İsimlendirme
301
+ - Uygulama adları küçük harf ve tire kullanın: `my-app`
302
+ - Açıklayıcı isimler seçin
303
+ - Benzersiz isimler kullanın
304
+
305
+ ### 2. Sürüm Yönetimi
306
+ - Semantic versioning kullanın: `1.0.0`
307
+ - Her değişiklikte sürüm artırın
308
+ - CHANGELOG.md dosyası ekleyin
309
+
310
+ ### 3. Dokümantasyon
311
+ - README.md dosyası ekleyin
312
+ - Kullanım örnekleri verin
313
+ - API dokümantasyonu ekleyin
314
+
315
+ ### 4. Hata Yönetimi
316
+ - Uygun hata mesajları verin
317
+ - Graceful degradation sağlayın
318
+ - Log dosyaları kullanın
319
+
320
+ ### 5. Güvenlik
321
+ - Hassas bilgileri kodlamayın
322
+ - Input validation yapın
323
+ - Güvenli dosya işlemleri kullanın
324
+
325
+ ### 6. Performans
326
+ - Gereksiz bağımlılıklardan kaçının
327
+ - Hızlı başlangıç sağlayın
328
+ - Bellek kullanımını optimize edin
329
+
330
+ ## 🆘 Yardım
331
+
332
+ ### Hata Ayıklama
333
+
334
+ ```bash
335
+ # Sistem durumunu kontrol et
336
+ clapp doctor
337
+
338
+ # Ortam kontrolü
339
+ clapp check-env
340
+
341
+ # Uygulama konumunu bul
342
+ clapp where my-app
343
+ ```
344
+
345
+ ### Destek
346
+
347
+ - GitHub Issues: [clapp repository](https://github.com/mburakmmm/clapp)
348
+ - Dokümantasyon: Bu rehber
349
+ - Örnekler: `templates/` klasörü
350
+
351
+ ## 📝 Örnekler
352
+
353
+ Daha fazla örnek için `templates/` klasörünü inceleyin:
354
+
355
+ - `templates/python/` - Python örnekleri
356
+ - `templates/lua/` - Lua örnekleri
357
+ - `templates/dart/` - Dart örnekleri
358
+ - `templates/go/` - Go örnekleri
359
+ - `templates/rust/` - Rust örnekleri
360
+
361
+ Her örnek tam çalışan bir uygulama içerir ve kopyalanıp değiştirilebilir.
main.py CHANGED
@@ -32,6 +32,12 @@ from clean_command import run_clean
32
32
  from where_command import locate_app_path, list_all_app_locations
33
33
  from version_command import print_version, print_detailed_version
34
34
 
35
+ # Yeni güvenlik ve performans modülleri
36
+ from package_signing import check_package_security
37
+ from version_manager import check_app_updates, get_app_latest_version, increment_app_version
38
+ from cache_manager import get_cache_stats, clear_all_caches, download_packages_parallel
39
+ from smart_search import search_packages, get_search_suggestions, get_search_analytics, clear_search_history
40
+
35
41
  # Yeni publish.cursorrules komutları
36
42
  from publish_command import publish_app
37
43
  from install_command import install_app
@@ -46,6 +52,9 @@ from dependency_resolver import (
46
52
  handle_dependency_tree
47
53
  )
48
54
 
55
+ # Yeni uygulama oluşturma komutu
56
+ from new_command import handle_new_command
57
+
49
58
  def main():
50
59
  """Ana CLI fonksiyonu"""
51
60
 
@@ -63,6 +72,7 @@ def main():
63
72
  clapp list # Yüklü uygulamaları listele
64
73
  clapp run hello-python # hello-python uygulamasını çalıştır
65
74
  clapp info hello-python # Uygulama bilgilerini göster
75
+ clapp new python my-app # Yeni Python uygulaması oluştur
66
76
 
67
77
  🔧 Yönetim Komutları:
68
78
  clapp install app.zip # ZIP dosyasından uygulama yükle
@@ -173,6 +183,34 @@ def main():
173
183
  version_parser.add_argument('--json', action='store_true', help='JSON formatında')
174
184
  version_parser.add_argument('--detailed', action='store_true', help='Detaylı bilgi')
175
185
 
186
+ # Güvenlik komutları
187
+ security_parser = subparsers.add_parser('security', help='Paket güvenlik işlemleri')
188
+ security_parser.add_argument('action', choices=['sign', 'verify', 'check'], help='Güvenlik işlemi')
189
+ security_parser.add_argument('package_path', help='Paket dosyası yolu')
190
+ security_parser.add_argument('--signature', help='İmza dosyası yolu (verify için)')
191
+
192
+ # Versiyon yönetimi komutları
193
+ update_parser = subparsers.add_parser('update', help='Versiyon yönetimi')
194
+ update_parser.add_argument('action', choices=['check', 'increment'], help='İşlem türü')
195
+ update_parser.add_argument('--app', help='Uygulama adı')
196
+ update_parser.add_argument('--type', choices=['major', 'minor', 'patch'], default='patch', help='Artırma tipi')
197
+
198
+ # Cache yönetimi komutları
199
+ cache_parser = subparsers.add_parser('cache', help='Cache yönetimi')
200
+ cache_parser.add_argument('action', choices=['stats', 'clear', 'download'], help='Cache işlemi')
201
+ cache_parser.add_argument('--urls', nargs='+', help='İndirilecek URL\'ler (download için)')
202
+ cache_parser.add_argument('--dest', help='Hedef dizin (download için)')
203
+
204
+ # Akıllı arama komutları
205
+ search_parser = subparsers.add_parser('search', help='Akıllı arama')
206
+ search_parser.add_argument('query', nargs='?', help='Arama sorgusu')
207
+ search_parser.add_argument('--suggestions', action='store_true', help='Arama önerileri')
208
+ search_parser.add_argument('--analytics', action='store_true', help='Arama analitikleri')
209
+ search_parser.add_argument('--clear-history', action='store_true', help='Arama geçmişini temizle')
210
+ search_parser.add_argument('--language', help='Dil filtresi')
211
+ search_parser.add_argument('--category', help='Kategori filtresi')
212
+ search_parser.add_argument('--sort', choices=['relevance', 'name', 'version', 'language'], default='relevance', help='Sıralama')
213
+
176
214
  # dependency komutu (yeni)
177
215
  dependency_parser = subparsers.add_parser('dependency', help='Bağımlılık yönetimi')
178
216
  dependency_subparsers = dependency_parser.add_subparsers(dest='dependency_command', help='Bağımlılık alt komutları')
@@ -194,6 +232,13 @@ def main():
194
232
  dep_tree_parser = dependency_subparsers.add_parser('tree', help='Bağımlılık ağacı')
195
233
  dep_tree_parser.add_argument('app_name', help='Uygulama adı')
196
234
 
235
+ # new komutu (yeni)
236
+ new_parser = subparsers.add_parser('new', help='Yeni uygulama oluştur')
237
+ new_parser.add_argument('language', nargs='?', help='Programlama dili')
238
+ new_parser.add_argument('app_name', nargs='?', help='Uygulama adı')
239
+ new_parser.add_argument('--list', action='store_true', help='Mevcut şablonları listele')
240
+ new_parser.add_argument('--target-dir', help='Hedef dizin (opsiyonel)')
241
+
197
242
  # Argümanları parse et
198
243
  args = parser.parse_args()
199
244
 
@@ -341,6 +386,153 @@ def main():
341
386
  else:
342
387
  print("❌ Geçersiz dependency komutu")
343
388
  sys.exit(1)
389
+
390
+ elif args.command == 'new':
391
+ # Yeni uygulama oluşturma komutu
392
+ success, message = handle_new_command(args)
393
+ if success:
394
+ print(message)
395
+ else:
396
+ print(f"❌ {message}")
397
+ sys.exit(1)
398
+
399
+ elif args.command == 'security':
400
+ if args.action == 'check':
401
+ results = check_package_security(args.package_path)
402
+ print("🔒 Paket Güvenlik Kontrolü")
403
+ print("=" * 40)
404
+ print(f"Bütünlük: {'✅' if results['integrity'] else '❌'}")
405
+ print(f"İmza: {'✅' if results['signature'] else '❌'}")
406
+ print(f"Checksum: {results['checksum']}")
407
+ if results['warnings']:
408
+ print("\n⚠️ Uyarılar:")
409
+ for warning in results['warnings']:
410
+ print(f" - {warning}")
411
+ else:
412
+ print("❌ İmzalama özelliği geçici olarak devre dışı")
413
+ sys.exit(1)
414
+
415
+ elif args.command == 'update':
416
+ if args.action == 'check':
417
+ if not args.app:
418
+ print("❌ --app parametresi gerekli")
419
+ sys.exit(1)
420
+
421
+ from package_registry import get_manifest
422
+ manifest = get_manifest(args.app)
423
+ if not manifest:
424
+ print(f"❌ {args.app} uygulaması bulunamadı")
425
+ sys.exit(1)
426
+
427
+ current_version = manifest.get('version', '0.0.0')
428
+ update_info = check_app_updates(args.app, current_version)
429
+
430
+ print(f"📦 {args.app} Güncelleme Kontrolü")
431
+ print("=" * 40)
432
+ print(f"Mevcut: {update_info['current_version']}")
433
+ print(f"En son: {update_info['latest_version'] or 'Bilinmiyor'}")
434
+ print(f"Durum: {update_info['message']}")
435
+
436
+ if update_info['has_update']:
437
+ print(f"Güncelleme tipi: {update_info['update_type']}")
438
+
439
+ elif args.action == 'increment':
440
+ if not args.app:
441
+ print("❌ --app parametresi gerekli")
442
+ sys.exit(1)
443
+
444
+ from package_registry import get_manifest
445
+ manifest = get_manifest(args.app)
446
+ if not manifest:
447
+ print(f"❌ {args.app} uygulaması bulunamadı")
448
+ sys.exit(1)
449
+
450
+ current_version = manifest.get('version', '0.0.0')
451
+ new_version = increment_app_version(current_version, args.type)
452
+ print(f"📦 {args.app} versiyonu artırıldı")
453
+ print(f"Eski: {current_version} → Yeni: {new_version}")
454
+
455
+ elif args.command == 'cache':
456
+ if args.action == 'stats':
457
+ stats = get_cache_stats()
458
+ print("📊 Cache İstatistikleri")
459
+ print("=" * 30)
460
+ print(f"Hit: {stats['hits']}")
461
+ print(f"Miss: {stats['misses']}")
462
+ print(f"Hit Rate: {stats['hit_rate']}%")
463
+ print(f"Boyut: {stats['size_mb']} MB")
464
+
465
+ elif args.action == 'clear':
466
+ deleted_count = clear_all_caches()
467
+ print(f"✅ {deleted_count} cache dosyası silindi")
468
+
469
+ elif args.action == 'download':
470
+ if not args.urls or not args.dest:
471
+ print("❌ --urls ve --dest parametreleri gerekli")
472
+ sys.exit(1)
473
+
474
+ os.makedirs(args.dest, exist_ok=True)
475
+ results = download_packages_parallel(args.urls, args.dest)
476
+
477
+ print("📥 Paralel İndirme Sonuçları")
478
+ print("=" * 40)
479
+ for success, message in results:
480
+ print(f"{'✅' if success else '❌'} {message}")
481
+
482
+ elif args.command == 'search':
483
+ if args.suggestions:
484
+ from package_registry import list_packages
485
+ packages = list_packages()
486
+ suggestions = get_search_suggestions(args.query or "", packages)
487
+ print("💡 Arama Önerileri")
488
+ print("=" * 20)
489
+ for suggestion in suggestions:
490
+ print(f" • {suggestion}")
491
+
492
+ elif args.analytics:
493
+ analytics = get_search_analytics()
494
+ print("📈 Arama Analitikleri")
495
+ print("=" * 25)
496
+ print(f"Toplam arama: {analytics['total_searches']}")
497
+ print(f"Benzersiz sorgu: {analytics['unique_queries']}")
498
+ print(f"Hit rate: {round(analytics['total_searches'] / max(1, analytics['unique_queries']) * 100, 1)}%")
499
+
500
+ if analytics['most_popular']:
501
+ print("\n🔥 Popüler Aramalar:")
502
+ for query, count in analytics['most_popular']:
503
+ print(f" • {query} ({count} kez)")
504
+
505
+ elif args.clear_history:
506
+ clear_search_history()
507
+
508
+ elif args.query:
509
+ from package_registry import list_packages
510
+ packages = list_packages()
511
+
512
+ filters = {}
513
+ if args.language:
514
+ filters['language'] = args.language
515
+ if args.category:
516
+ filters['category'] = args.category
517
+ if args.sort:
518
+ filters['sort_by'] = args.sort
519
+
520
+ results = search_packages(args.query, packages, filters)
521
+
522
+ print(f"🔍 '{args.query}' için {len(results)} sonuç bulundu")
523
+ print("=" * 50)
524
+
525
+ for package in results:
526
+ score = package.get('search_score', 0)
527
+ print(f"📦 {package['name']} v{package['version']} ({package['language']})")
528
+ print(f" {package['description']}")
529
+ if score > 0:
530
+ print(f" Skor: {score:.2f}")
531
+ print()
532
+
533
+ else:
534
+ print("❌ Arama sorgusu gerekli veya --suggestions/--analytics kullanın")
535
+ sys.exit(1)
344
536
 
345
537
  except KeyboardInterrupt:
346
538
  print("\n❌ İşlem iptal edildi")
manifest_schema.py CHANGED
@@ -42,7 +42,11 @@ def validate_manifest(manifest):
42
42
  # Opsiyonel alanlar
43
43
  optional_fields = {
44
44
  'description': str,
45
- 'dependencies': list
45
+ 'dependencies': list,
46
+ 'author': str,
47
+ 'license': str,
48
+ 'tags': list,
49
+ 'category': str
46
50
  }
47
51
 
48
52
  # Gerekli alanları kontrol et
@@ -52,9 +56,16 @@ def validate_manifest(manifest):
52
56
  if not isinstance(manifest[field], expected_type):
53
57
  return False
54
58
 
55
- # Dil kontrolü
56
- if manifest['language'] not in ['python', 'lua']:
57
- return False
59
+ # Dil kontrolü - package_runner'dan desteklenen dilleri al
60
+ try:
61
+ from package_runner import get_supported_languages
62
+ supported_languages = get_supported_languages()
63
+ if manifest['language'] not in supported_languages:
64
+ return False
65
+ except ImportError:
66
+ # Fallback: Temel diller
67
+ if manifest['language'] not in ['python', 'lua', 'dart', 'go', 'rust', 'node', 'bash', 'perl', 'ruby', 'php']:
68
+ return False
58
69
 
59
70
  # Opsiyonel alanları kontrol et (varsa)
60
71
  for field, expected_type in optional_fields.items():
@@ -79,6 +90,10 @@ def get_schema():
79
90
  },
80
91
  "optional_fields": {
81
92
  "description": "string",
82
- "dependencies": "list"
93
+ "dependencies": "list",
94
+ "author": "string",
95
+ "license": "string",
96
+ "tags": "list",
97
+ "category": "string"
83
98
  }
84
99
  }
manifest_validator.py CHANGED
@@ -39,8 +39,8 @@ def validate_manifest_verbose(manifest):
39
39
  elif field == "language":
40
40
  if not isinstance(value, str):
41
41
  errors.append(f"'{field}' alanı string olmalı")
42
- elif value.lower() not in ["python", "lua"]:
43
- errors.append(f"'{field}' alanı 'python' veya 'lua' olmalı, '{value}' geçersiz")
42
+ elif value.lower() not in ["python", "lua", "dart", "go", "rust", "node", "bash", "perl", "ruby", "php"]:
43
+ errors.append(f"'{field}' alanı desteklenen bir dil olmalı, '{value}' geçersiz")
44
44
  elif field == "entry":
45
45
  if not isinstance(value, str) or not value.strip():
46
46
  errors.append(f"'{field}' alanı boş olmayan bir string olmalı")
@@ -61,7 +61,7 @@ def validate_manifest_verbose(manifest):
61
61
  errors.append(f"'dependencies[{i}]' boş olmayan bir string olmalı")
62
62
 
63
63
  # Bilinmeyen alanları kontrol et
64
- known_fields = set(required_fields.keys()) | {"description", "dependencies"}
64
+ known_fields = set(required_fields.keys()) | {"description", "dependencies", "author", "license", "tags", "category"}
65
65
  for field in manifest.keys():
66
66
  if field not in known_fields:
67
67
  errors.append(f"Bilinmeyen alan: '{field}' (göz ardı edilecek)")