We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 129e798 commit 67083e1Copy full SHA for 67083e1
lib/git/base.rb
@@ -264,6 +264,11 @@ def reset_hard(commitish = nil, opts = {})
264
self.lib.reset(commitish, opts)
265
end
266
267
+ def clean(opts = {})
268
+ opts = { :force => true, :d => true }.merge(opts)
269
+ self.lib.clean(opts)
270
+ end
271
+
272
# commits all pending changes in the index file to the git repository
273
#
274
# options:
lib/git/lib.rb
@@ -431,6 +431,13 @@ def reset(commit, opts = {})
431
arr_opts << commit if commit
432
command('reset', arr_opts)
433
434
435
436
+ arr_opts = []
437
+ arr_opts << '--force' if opts[:force]
438
+ arr_opts << '-d' if opts[:d]
439
+ command('clean', arr_opts)
440
441
442
def apply(patch_file)
443
arr_opts = []
0 commit comments