Skip to content
This repository has been archived by the owner on Jul 12, 2020. It is now read-only.

Rewrite config #272

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
30 changes: 23 additions & 7 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,20 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.

## [Unreleased]

### Added

- new `YoutubeDownloader\Config\TransformationConfig` for a BC friendly configuraion

### Changed

- Moved configuration `$config['ThumbnailImageMode']` to `$config['gui']['ThumbnailImageMode']`
- Moved configuration `$config['VideoLinkMode']` to `$config['gui']['VideoLinkMode']`
- Moved configuration `$config['showBrowserExtensions']` to `$config['gui']['showBrowserExtensions']`

### Deprecated

- `YoutubeDownloader\Config` will be removed in 0.8, use `YoutubeDownloader\Config\TransformationConfig` instead

### Removed

- **Breaking:** `YoutubeDownloader\Provider\Youtube\Provider::createFromConfigAndToolkit()` was removed, use `YoutubeDownloader\Provider\Youtube\Provider::createFromOptions()` instead
Expand All @@ -20,21 +34,23 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.

### Added

- new `YoutubeDownloader\Config\TransformationConfig` for a BC friendly configuraion
- new `YoutubeDownloader\Provider\Youtube\Provider::createFromOptions()` to create the Youtube Provider with an options array
- new `YoutubeDownloader\Provider\Youtube\VideoInfo::createFromStringWithOptions()` to create the Youtube VideoInfo with an options array
- New support for creation of RSS feeds from YouTube channels and user pages
- `YoutubeDownloader\Provider\Youtube\Provider::createFromOptions()` to create the Youtube Provider with an options array
- `YoutubeDownloader\Provider\Youtube\VideoInfo::createFromStringWithOptions()` to create the Youtube VideoInfo with an options array

### Changed

- Support for PHP 5.4 and 5.5 was dropped
- The mp3 downloader was improved and has no dependendy to aria2 anymore
- Moved configuration `$config['ThumbnailImageMode']` to `$config['gui']['ThumbnailImageMode']`
- Moved configuration `$config['VideoLinkMode']` to `$config['gui']['VideoLinkMode']`
- Moved configuration `$config['showBrowserExtensions']` to `$config['gui']['showBrowserExtensions']`
- Code Style was changed to PSR-2

### Fixed

- A bug in the downlaoder with adaptive format was fixed
- The path to the yearly logs folder was fixed

### Deprecated

- `YoutubeDownloader\Config` will be removed in 0.7, use `YoutubeDownloader\Config\TransformationConfig` instead
- `YoutubeDownloader\Provider\Youtube\Provider::createFromConfigAndToolkit()` will be removed in 0.7, use `YoutubeDownloader\Provider\Youtube\Provider::createFromOptions()` instead
- `YoutubeDownloader\Provider\Youtube\VideoInfo::createFromStringWithConfig()` will be removed in 0.7, use `YoutubeDownloader\Provider\Youtube\VideoInfo::createFromStringWithOptions()` instead
- `YoutubeDownloader\Toolkit::validateVideoId()` isn't used anymore and will be removed in 0.7
Expand Down
14 changes: 7 additions & 7 deletions config/default.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
*/
$config['debug'] = false;

/**
/*
* Enable the YouTube signature decipher function
* WARNING: This downloads javascript code from a 3rd party server and interprets it!
* This MAY harm your server, if the 3rd party server delivers malicious code!
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it would be impossible to execute malicious code with the current decipher script. The current decipher didn't execute the raw code instead using matched command dictionary to reverse, splice, or swapping signature arrays..

Expand All @@ -27,7 +27,7 @@
*/
$config['enable_youtube_decipher_signature'] = false;

/**
/*
* Thumbnail Image Configuration
*
* 'none' => don't show thumbnail image
Expand All @@ -36,22 +36,22 @@
*/
$config['gui']['ThumbnailImageMode'] = 'proxy';

/**
/*
* Video Download Link Configuration
* 'direct' => show only direct download link
* 'proxy' => show only by proxy download link
* 'both' => show both direct and by proxy download links
*/
$config['gui']['VideoLinkMode'] = 'both';

/**
/*
* show links for install browser extensions?
*
* true or false
*/
$config['gui']['showBrowserExtensions'] = true;

/**
/*
* MP3 Download Link Configuration
*
* Basic method for converting Youtube Video or Audio to .mp3
Expand All @@ -73,7 +73,7 @@
$config['ffmpegPath'] = 'C:\Program Files (x86)\ffmpeg\ffmpeg.exe'; // ffmpeg location path
$config['aria2Path'] = 'C:\cygwin\bin\aria2c.exe'; // aria2 location path, @deprecated since 0.6, to be removed in 0.7

/**
/*
* Multiple IPs
*
* You can enable this option if you are having problems with youtube IP limit / IP ban.
Expand Down Expand Up @@ -141,7 +141,7 @@
//'xxx.xxx.xxx.xxx',
];

/**
/*
* Set your default timezone
*
* e.g. Asia/Tehran or America/New_York
Expand Down
You are viewing a condensed version of this merge commit. You can view the full changes here.