Skip to content

Commit

Permalink
fix: travis ci
Browse files Browse the repository at this point in the history
  • Loading branch information
Markkop committed Apr 23, 2020
1 parent cc58cb5 commit 585d6c3
Show file tree
Hide file tree
Showing 3 changed files with 64 additions and 25 deletions.
56 changes: 42 additions & 14 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,23 +1,51 @@
language: node_js
node_js: '10.18.0'
os: linux
dist: xenial
node_js: '11.6.0'

jobs:
include:
- os: linux
dist: trusty
services: docker
language: generic

- os: windows
language: node_js
node_js: '10'
env:
- YARN_GPG=no
- ELECTRON_CACHE=$HOME/.cache/electron
- ELECTRON_BUILDER_CACHE=$HOME/.cache/electron-builder

cache:
yarn: true
directories:
- node_modules
- $HOME/.cache/electron
- $HOME/.cache/electron-builder
- $HOME/.npm/_prebuilds

env:
global:
- ELECTRON_CACHE=$HOME/.cache/electron
- ELECTRON_BUILDER_CACHE=$HOME/.cache/electron-builder
script:
- yarn build
- |
if [ "$TRAVIS_OS_NAME" == "linux" ]; then
docker run --rm \
-v ${PWD}:/project \
-v ~/.cache/electron:/root/.cache/electron \
-v ~/.cache/electron-builder:/root/.cache/electron-builder \
electronuserland/builder:wine \
/bin/bash -c "yarn --link-duplicates --pure-lockfile && yarn dist:linux"
else
yarn dist:win
fi
jobs:
include:
- stage: Deploy linux
if: tag IS present
os: linux
dist: trusty
script:
- npm run release
deploy:
provider: releases
token: $GH_TOKEN
file_glob: true
file:
- 'dist/*.AppImage'
- 'dist/*.exe'
overwrite: true
on:
all_branches: true
29 changes: 20 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,17 +5,28 @@

## What it is

This tool downloads a Youtube video to `videos` folder and cuts it given a starting and an ending time.\
The time must be in the format `HH:MM:SS` and the duration can't be longer than 24 hours.
This app downloads youtube videos using youtube-dl and cuts them with ffmpeg given starting and ending times.
Currently only Windows e Linux platforms are supported.

## How to use

- Install NodeJS and ffmpeg
- Clone or download this repository
- Run `npm start` inside the project's folder
- Provide required information
- Check `videos` folder
Download the binary according to your OS:

## User Options
- Linux
- Windows

![An example of user options](http://i.imgur.com/avvmjF8.png)
## How to develop

Clone this repository and run `yarn` to install dependencies.
Make sure to have `node` and `npm` installed.

## Options

- Youtube url (required)
Can be a shortened version or a normal one

- Starting and ending times (required)
In the HH:MM:SS format. It can't be longer than 24h

- Convert to mp3
It converts the same output to mp3
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "yt-dlandcut",
"version": "2.0.0",
"version": "2.0.1",
"description": "Download and Cut an Youtube video by its starting and ending times",
"repository": "github:markkop/yt-dlandcut",
"main": "build/electron/main.js",
Expand All @@ -12,7 +12,7 @@
"dist:win": "electron-builder build --win portable ",
"dist": "electron-builder build --win portable --linux AppImage ",
"build": "babel src --out-dir build",
"release": "build"
"release": "yarn build && electron-builder"
},
"keywords": [],
"author": "Marcelo 'Mark' Kopmann",
Expand Down

0 comments on commit 585d6c3

Please sign in to comment.