lib/octofacts_updater/service/github.rb
# Delete a file from the repository. Because of the way the GitHub API works, this will generate an
# immediate commit and push. It will NOT be batched for later application.
#
# path    - A String with the path at which to commit the file
# message - A String with a commit message, defaults to the overall configured commit message.
#
# Returns true if the file existed before and was deleted. Returns false if the file didn't exist anyway.
Delete a file from the repository. Because of the way the GitHub API works, this will generate an
immediate commit and push. It will NOT be batched for later application.

path    - A String with the path at which to commit the file
message - A String with a commit message, defaults to the overall configured commit message.

Returns true if the file existed before and was deleted. Returns false if the file didn't exist anyway.
Delete a file from the repository . Because of the way the GitHub API works this will generate an immediate commit and push . It will NOT be batched for later application . path - A String with the path at which to commit the file message - A String with a commit message defaults to the overall configured commit message . Returns true if the file existed before and was deleted . Returns false if the file didn ' t exist anyway .
def delete_file(path, message = commit_message)
        ensure_branch_exists
        contents = octokit.contents(repository, path: path, ref: branch)
        blob_sha = contents.sha
        octokit.delete_contents(repository, path, message, blob_sha, branch: branch)
        verbose("Deleted #{path}")
        find_or_create_pull_request
        true
      rescue Octokit::NotFound
        verbose("Deleted #{path} (already gone)")
        false
      end
def delete_file ( path , message = commit_message ) ensure_branch_exists contents = octokit . contents ( repository , path : path , ref : branch ) blob_sha = contents . sha octokit . delete_contents ( repository , path , message , blob_sha , branch : branch ) verbose ( "Deleted #{path}" ) find_or_create_pull_request true rescue Octokit :: NotFound verbose ( "Deleted #{path} (already gone)" ) false end
Delete a file from the repository.
Delete a file from the repository .
path
<not_specific>
message
<not_specific>
commit_message
<not_specific>