Skip to content

Commit

Permalink
Remove dry-run flag from dns purge as it doesn't do anything (#70)
Browse files Browse the repository at this point in the history
  • Loading branch information
Cyb3r-Jak3 authored Mar 16, 2024
1 parent 589f36b commit 05859a8
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 9 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -23,5 +23,5 @@ test:
docs:
cd documentation && mkdocs build

doc-serve:
docs-serve:
cd documentation && docker run --rm -v $(DOCS_DIR):/docs -p 8000:8000 ghcr.io/squidfunk/mkdocs-material:9.5.4
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

[![GitHub release (latest SemVer)](https://img.shields.io/github/v/release/Cyb3r-Jak3/cloudflare-utils)](https://github.com/Cyb3r-Jak3/cloudflare-utils/releases/latest)

[![Go Checks](https://github.com/Cyb3r-Jak3/cloudflare-utils/actions/workflows/golang.yml/badge.svg)](https://github.com/Cyb3r-Jak3/cloudflare-utils/actions/workflows/golang.yml) [![Golanglint CI](https://github.com/Cyb3r-Jak3/cloudflare-utils/actions/workflows/golangci-lint.yml/badge.svg)](https://github.com/Cyb3r-Jak3/cloudflare-utils/actions/workflows/golangci-lint.yml)
[![Go Checks](https://github.com/Cyb3r-Jak3/cloudflare-utils/actions/workflows/golang.yml/badge.svg)](https://github.com/Cyb3r-Jak3/cloudflare-utils/actions/workflows/golang.yml) [![GolangLint CI](https://github.com/Cyb3r-Jak3/cloudflare-utils/actions/workflows/golangci-lint.yml/badge.svg)](https://github.com/Cyb3r-Jak3/cloudflare-utils/actions/workflows/golangci-lint.yml)

![GitHub all releases](https://img.shields.io/github/downloads/Cyb3r-Jak3/cloudflare-utils/total?label=GitHub%20Total%20Downloads) ![Chocolatey](https://img.shields.io/chocolatey/dt/cloudflare-utils?label=Chocolatey%20Downloads)

Expand All @@ -14,6 +14,7 @@ This is a collection of utilities for Cloudflare. The utilities are written in G
* [DNS Purge](https://cloudflare-utils.cyberjake.xyz/dns/purge/)
* [Deployment Purge](https://cloudflare-utils.cyberjake.xyz/pages/purge-deployments/)
* [Deployment Prune](https://cloudflare-utils.cyberjake.xyz/pages/prune-deployments/)
* [List Tunnel Version](https://cloudflare-utils.cyberjake.xyz/tunnels/list-versions/)

## Installation

Expand All @@ -25,7 +26,7 @@ choco install cloudflare-utils

### GitHub

Download the latest release from the [releases page]()
Download the latest release from the [releases page](https://github.com/Cyb3r-Jak3/cloudflare-utils/releases/latest)

### Docker

Expand Down
5 changes: 0 additions & 5 deletions cmd/cloudflare-utils/dns-purge.go
Original file line number Diff line number Diff line change
Expand Up @@ -62,11 +62,6 @@ func DNSPurge(c *cli.Context) error {
return nil
}

if c.Bool(dryRunFlag) {
fmt.Printf("Dry run: Would have deleted %d records\n", len(records))
return nil
}

errors := RapidDNSDelete(c.Context, zoneResource, records)
errorCount := len(errors)

Expand Down
1 change: 0 additions & 1 deletion documentation/docs/dns/purge.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ Once you have it downloaded run `cloudflare-utils --api-token <API Token with DN

Optional flags:

- `--dry-run`: See what would be deleted without actually deleting anything.
- `--confirm`: Skip the confirmation prompt.


Expand Down

0 comments on commit 05859a8

Please sign in to comment.