Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
version: 2
updates:
- package-ecosystem: "maven"
directory: "/"
schedule:
interval: "weekly"
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
8 changes: 4 additions & 4 deletions .github/workflows/maven.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,15 @@ jobs:
strategy:
matrix:
# Long term supported versions
java-version: [8, 11, 17, 21]
java-version: [11, 17, 21]

# TODO Should we test locales? The old travis setup did, see:
# https://github.com/bramp/ffmpeg-cli-wrapper/pull/55

name: JDK ${{ matrix.java-version }}

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4

- name: Set up FFmpeg
uses: FedericoCarboni/setup-ffmpeg@v3
Expand All @@ -35,7 +35,7 @@ jobs:
ffmpeg-version: release

- name: Set up JDK ${{ matrix.java-version }}
uses: actions/setup-java@v3
uses: actions/setup-java@v4
with:
java-version: ${{ matrix.java-version }}
distribution: 'temurin'
Expand Down
53 changes: 53 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
# This workflow will build a Java project with Maven, and cache/restore any dependencies to improve the workflow execution time
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-java-with-maven

name: Java CI with Maven

on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]

jobs:
build:
runs-on: ubuntu-latest
# Enable debugging to help resolve:
# https://github.com/federicocarboni/setup-ffmpeg/issues/19
environment: debug
strategy:
matrix:
# Long term supported versions
java-version: [11, 17, 21]

# TODO Should we test locales? The old travis setup did, see:
# https://github.com/bramp/ffmpeg-cli-wrapper/pull/55

name: JDK ${{ matrix.java-version }}

steps:
- uses: actions/checkout@v4

- name: Set up FFmpeg
uses: FedericoCarboni/setup-ffmpeg@v3
id: setup-ffmpeg
with:
ffmpeg-version: release

- name: Set up JDK ${{ matrix.java-version }}
uses: actions/setup-java@v4
with:
java-version: ${{ matrix.java-version }}
distribution: 'temurin'
cache: maven

- name: Compile with Maven
run: mvn --batch-mode --update-snapshots compile

- name: Test with Maven, Package and Verify with Maven
run: mvn --batch-mode --update-snapshots verify -Dgpg.skip

# Optional: Uploads the full dependency graph to GitHub to improve the quality of Dependabot alerts this repository can receive
- name: Update dependency graph
uses: advanced-security/maven-dependency-submission-action@v4
continue-on-error: true
25 changes: 25 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.5.0
hooks:
- id: check-yaml
args: [--allow-multiple-documents]
- id: end-of-file-fixer
exclude: ^src/test/resources/
- id: trailing-whitespace
exclude: ^src/test/resources/
- repo: local
hooks:
- id: maven-format
name: Maven Format
entry: mvn fmt:format
language: system
types: [java]
pass_filenames: false

- id: maven-test
name: Maven Test
entry: mvn test
language: system
types: [java]
pass_filenames: false
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ by Andrew Brampton ([bramp.net](https://bramp.net)) (c) 2013-2024

A fluent interface for running FFmpeg from Java.

![Java](https://img.shields.io/badge/Java-8+-brightgreen.svg)
[![Build Status](https://github.com/bramp/ffmpeg-cli-wrapper/actions/workflows/maven.yml/badge.svg)](https://github.com/bramp/ffmpeg-cli-wrapper/actions/workflows/maven.yml)
![Java](https://img.shields.io/badge/Java-11+-brightgreen.svg)
[![Build Status](https://github.com/bramp/ffmpeg-cli-wrapper/actions/workflows/test.yml/badge.svg)](https://github.com/bramp/ffmpeg-cli-wrapper/actions/workflows/test.yml)
[![Coverage Status](https://img.shields.io/coveralls/bramp/ffmpeg-cli-wrapper.svg)](https://coveralls.io/github/bramp/ffmpeg-cli-wrapper)
[![Maven](https://img.shields.io/maven-central/v/net.bramp.ffmpeg/ffmpeg.svg)](http://mvnrepository.com/artifact/net.bramp.ffmpeg/ffmpeg)
[![Libraries.io](https://img.shields.io/librariesio/github/bramp/ffmpeg-cli-wrapper.svg)](https://libraries.io/github/bramp/ffmpeg-cli-wrapper)
Expand All @@ -16,7 +16,7 @@ A fluent interface for running FFmpeg from Java.

## Install

We currently support Java 8 and above. Use Maven to install the dependency.
We currently support Java 11 and above. Use Maven to install the dependency.

```xml
<dependency>
Expand Down Expand Up @@ -78,7 +78,7 @@ FFprobe ffprobe = new FFprobe("/path/to/ffprobe");
FFmpegProbeResult probeResult = ffprobe.probe("input.mp4");

FFmpegFormat format = probeResult.getFormat();
System.out.format("%nFile: '%s' ; Format: '%s' ; Duration: %.3fs",
System.out.format("%nFile: '%s' ; Format: '%s' ; Duration: %.3fs",
format.filename,
format.format_long_name,
format.duration
Expand Down Expand Up @@ -158,7 +158,7 @@ mvn clean javadoc:aggregate scm-publish:publish-scm
mvn versions:display-plugin-updates

# Library Dependencies
mvn versions:display-dependency-updates
mvn versions:display-dependency-updates
```

## Install FFmpeg on Ubuntu
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -535,7 +535,7 @@
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>taglist-maven-plugin</artifactId>
<version>3.0.0</version>
<version>3.2.2</version>
<configuration>
<aggregate>true</aggregate>
<tagListOptions>
Expand Down
Loading