Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
D
django
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
django
Commits
48d92fea
Kaydet (Commit)
48d92fea
authored
Agu 18, 2017
tarafından
jkrzy
Kaydeden (comit)
Tim Graham
Eyl 02, 2017
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Fixed #28367 -- Doc'd how to override management commands.
üst
54f7aa04
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
0 deletions
+18
-0
custom-management-commands.txt
docs/howto/custom-management-commands.txt
+18
-0
No files found.
docs/howto/custom-management-commands.txt
Dosyayı görüntüle @
48d92fea
...
...
@@ -181,6 +181,24 @@ Testing
Information on how to test custom management commands can be found in the
:ref:`testing docs <topics-testing-management-commands>`.
Overriding commands
===================
Django registers the built-in commands and then searches for commands in
:setting:`INSTALLED_APPS` in reverse. During the search, if a command name
duplicates an already registered command, the newly discovered command
overrides the first.
In other words, to override a command, the new command must have the same name
and its app must be before the overridden command's app in
:setting:`INSTALLED_APPS`.
Management commands from third-party apps that have been unintentionally
overridden can be made available under a new name by creating a new command in
one of your project's apps (ordered before the third-party app in
:setting:`INSTALLED_APPS`) which imports the ``Command`` of the overridden
command.
Command objects
===============
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment