forked from qt-creator/qt-creator
Git: Enable --no-verify for commit
Change-Id: I88cfb7839b41467e3f6b25bea329eb15765e440e Reviewed-by: Tobias Hunger <tobias.hunger@nokia.com>
This commit is contained in:
committed by
Tobias Hunger
parent
63f0c0a62f
commit
6a3f9460d7
@@ -58,6 +58,7 @@ void GitSubmitEditorPanelData::clear()
|
|||||||
{
|
{
|
||||||
author.clear();
|
author.clear();
|
||||||
email.clear();
|
email.clear();
|
||||||
|
bypassHooks = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
QString GitSubmitEditorPanelData::authorString() const
|
QString GitSubmitEditorPanelData::authorString() const
|
||||||
@@ -76,7 +77,8 @@ QString GitSubmitEditorPanelData::authorString() const
|
|||||||
|
|
||||||
QDebug operator<<(QDebug d, const GitSubmitEditorPanelData &data)
|
QDebug operator<<(QDebug d, const GitSubmitEditorPanelData &data)
|
||||||
{
|
{
|
||||||
d.nospace() << " author:" << data.author << " email: " << data.email;
|
d.nospace() << " author:" << data.author << " email: " << data.email
|
||||||
|
<< " bypass hooks: " << data.bypassHooks;
|
||||||
return d;
|
return d;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -62,6 +62,7 @@ struct GitSubmitEditorPanelData
|
|||||||
|
|
||||||
QString author;
|
QString author;
|
||||||
QString email;
|
QString email;
|
||||||
|
bool bypassHooks;
|
||||||
};
|
};
|
||||||
|
|
||||||
QDebug operator<<(QDebug d, const GitSubmitEditorPanelData &);
|
QDebug operator<<(QDebug d, const GitSubmitEditorPanelData &);
|
||||||
|
@@ -1874,6 +1874,8 @@ bool GitClient::addAndCommit(const QString &repositoryDirectory,
|
|||||||
const QString &authorString = data.authorString();
|
const QString &authorString = data.authorString();
|
||||||
if (!authorString.isEmpty())
|
if (!authorString.isEmpty())
|
||||||
args << QLatin1String("--author") << authorString;
|
args << QLatin1String("--author") << authorString;
|
||||||
|
if (data.bypassHooks)
|
||||||
|
args << QLatin1String("--no-verify");
|
||||||
|
|
||||||
QByteArray outputText;
|
QByteArray outputText;
|
||||||
QByteArray errorText;
|
QByteArray errorText;
|
||||||
|
@@ -143,6 +143,7 @@ GitSubmitEditorPanelData GitSubmitEditorWidget::panelData() const
|
|||||||
GitSubmitEditorPanelData rc;
|
GitSubmitEditorPanelData rc;
|
||||||
rc.author = m_gitSubmitPanelUi.authorLineEdit->text();
|
rc.author = m_gitSubmitPanelUi.authorLineEdit->text();
|
||||||
rc.email = m_gitSubmitPanelUi.emailLineEdit->text();
|
rc.email = m_gitSubmitPanelUi.emailLineEdit->text();
|
||||||
|
rc.bypassHooks = m_gitSubmitPanelUi.bypassHooksCheckBox->isChecked();
|
||||||
return rc;
|
return rc;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -150,6 +151,7 @@ void GitSubmitEditorWidget::setPanelData(const GitSubmitEditorPanelData &data)
|
|||||||
{
|
{
|
||||||
m_gitSubmitPanelUi.authorLineEdit->setText(data.author);
|
m_gitSubmitPanelUi.authorLineEdit->setText(data.author);
|
||||||
m_gitSubmitPanelUi.emailLineEdit->setText(data.email);
|
m_gitSubmitPanelUi.emailLineEdit->setText(data.email);
|
||||||
|
m_gitSubmitPanelUi.bypassHooksCheckBox->setChecked(data.bypassHooks);
|
||||||
authorInformationChanged();
|
authorInformationChanged();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -7,7 +7,7 @@
|
|||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>364</width>
|
<width>364</width>
|
||||||
<height>172</height>
|
<height>177</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QVBoxLayout" name="verticalLayout">
|
<layout class="QVBoxLayout" name="verticalLayout">
|
||||||
@@ -60,23 +60,6 @@
|
|||||||
<string>Commit Information</string>
|
<string>Commit Information</string>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QGridLayout" name="gridLayout">
|
<layout class="QGridLayout" name="gridLayout">
|
||||||
<item row="0" column="0">
|
|
||||||
<widget class="QLabel" name="authorLabel">
|
|
||||||
<property name="text">
|
|
||||||
<string>Author:</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="0" column="1">
|
|
||||||
<widget class="QLineEdit" name="authorLineEdit">
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>150</width>
|
|
||||||
<height>0</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="0" column="2">
|
<item row="0" column="2">
|
||||||
<widget class="QLabel" name="invalidAuthorLabel">
|
<widget class="QLabel" name="invalidAuthorLabel">
|
||||||
<property name="minimumSize">
|
<property name="minimumSize">
|
||||||
@@ -93,22 +76,6 @@
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="0" column="3">
|
|
||||||
<spacer name="horizontalSpacer">
|
|
||||||
<property name="orientation">
|
|
||||||
<enum>Qt::Horizontal</enum>
|
|
||||||
</property>
|
|
||||||
<property name="sizeType">
|
|
||||||
<enum>QSizePolicy::MinimumExpanding</enum>
|
|
||||||
</property>
|
|
||||||
<property name="sizeHint" stdset="0">
|
|
||||||
<size>
|
|
||||||
<width>5</width>
|
|
||||||
<height>20</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</spacer>
|
|
||||||
</item>
|
|
||||||
<item row="1" column="0">
|
<item row="1" column="0">
|
||||||
<widget class="QLabel" name="emailLabel">
|
<widget class="QLabel" name="emailLabel">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
@@ -142,6 +109,46 @@
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
|
<item row="0" column="0">
|
||||||
|
<widget class="QLabel" name="authorLabel">
|
||||||
|
<property name="text">
|
||||||
|
<string>Author:</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="1">
|
||||||
|
<widget class="QLineEdit" name="authorLineEdit">
|
||||||
|
<property name="minimumSize">
|
||||||
|
<size>
|
||||||
|
<width>150</width>
|
||||||
|
<height>0</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="3">
|
||||||
|
<spacer name="horizontalSpacer">
|
||||||
|
<property name="orientation">
|
||||||
|
<enum>Qt::Horizontal</enum>
|
||||||
|
</property>
|
||||||
|
<property name="sizeType">
|
||||||
|
<enum>QSizePolicy::MinimumExpanding</enum>
|
||||||
|
</property>
|
||||||
|
<property name="sizeHint" stdset="0">
|
||||||
|
<size>
|
||||||
|
<width>5</width>
|
||||||
|
<height>20</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
</spacer>
|
||||||
|
</item>
|
||||||
|
<item row="2" column="0">
|
||||||
|
<widget class="QCheckBox" name="bypassHooksCheckBox">
|
||||||
|
<property name="text">
|
||||||
|
<string>By&pass hooks</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
|
Reference in New Issue
Block a user