PdfToolCli 1.3.1

dotnet tool install --global PdfToolCli --version 1.3.1
This package contains a .NET tool you can call from the shell/command line.
dotnet new tool-manifest # if you are setting up this repo
dotnet tool install --local PdfToolCli --version 1.3.1
This package contains a .NET tool you can call from the shell/command line.
#tool dotnet:?package=PdfToolCli&version=1.3.1
nuke :add-package PdfToolCli --version 1.3.1

PdfToolCli

NuGet version

PdfToolCli is the command line tool that simply rotate and select pages in PDF documents, also this tool is able to merge multiple PDF files.

This is .NET Core tool.

How to use

Rotate

Rotate all page

Rotate all pages in target PDF document to specified angle.

Syntax
$ pdftool rotate all <PdfFilePath> <Angle>
Argument Description
PdfFilePath Target PDF file path.
Angle Rotate right: 90, 180, 270. Rotate left: -90, -180, -270.
Options
Otion Function
-o, --output Output file path that you want to save to.
Example

Rotate all pages to left 90° and save to 'output.pdf'.

$ pdftool rotate all MyPdf.pdf -90 -o output.pdf

Rotate specified pages

Rotate specified pages in target PDF document to specified angle.

Syntax
$ pdftool rotate pages <PdfFilePath> <pageNum1:angle1,pageNum2:angle2,...>
Argument Description
PdfFilePath Target PDF file path.
pageNum:angle Rotate 'pageNum'-th page to 'angle'°.
Options
Otion Function
-o, --output Output file path that you want to save to.
Example

Rotate 1,2,5th page to right 180° and rotate 3rd page to left 90° and save to 'output.pdf'.

$ pdftool rotate pages MyPdf.pdf 1:180,2:180,3:-90,5:180 -o output.pdf

or

$ pdftool rotate pages MyPdf.pdf 1-2:180,3:-90,5:180 -o output.pdf

Select

Select specified pages

Select and save specified page in target PDF document.

Syntax

$ pdftool select pages <PdfFilePath> <pageNum1,pageNum2,...>
Argument Description
PdfFilePath Target PDF file path.
pageNum Page number that you want to select.
Options
Otion Function
-o, --output Output file path that you want to save to.
Example

Select 1,2,3,5th page and save to 'output.pdf'.

$ pdftool select pages MyPdf.pdf 1,2,3,5 -o output.pdf

or

$ pdftool select pages MyPdf.pdf 1-3,5 -o output.pdf

Info

Show PDF file information

Show information about target PDF document.

Syntax

$ pdftool info count <PdfFilePath>
Argument Description
PdfFilePath Target PDF file path.
Options

No options.

Example

Show page count of target PDF document.

$ pdftool info count MyPdf.pdf

result

'MyPdf.pdf' has 10 pages.

Merge

Merge multiple PDF files

Merge multiple PDF files and save.

Syntax

$ pdftool merge files <PdfFilePath1,PdfFilePath2,PdfFilePath3,...>
Argument Description
List of PdfFilePath Comma separated list of target files you want to merge.
Options
Otion Function
-o, --output Output file path that you want to save to.
Example

Merge 3 PDF files(MyPdf1.pdf, MyPdf2.pdf and MyPdf3.pdf) and save it to output.pdf.

$ pdftool merge files MyPdf1.pdf,MyPdf2.pdf,MyPdf3.pdf -o output.pdf
Product Compatible and additional computed target framework versions.
.NET net5.0 was computed.  net5.0-windows was computed.  net6.0 was computed.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
.NET Core netcoreapp3.1 is compatible. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

This package has no dependencies.

Version Downloads Last updated
1.3.1 468 10/26/2020
1.3.0 333 10/26/2020
1.2.4 348 10/23/2020
1.2.3 403 10/22/2020
1.1.0 380 10/21/2020
1.0.0 415 10/21/2020