2018-02-22 16:11:19 +00:00
# Prepare everything
2018-11-10 10:00:20 +00:00
Welcome to the NewPipeExtractor documentation. This tutorial will guide you through the process of creating your own Extractor
service with which NewPipe will gain support for a dedicated streaming service like YouTube, Vimeo or SoundCloud.
The whole documentation consists of this page, which explains the general concept of the NewPipeExtractor, as well as our
[Jdoc ](https://teamnewpipe.github.io/NewPipeExtractor/javadoc/ ) setup.
2018-12-12 02:14:05 +00:00
__IMPORTANT!!!__ this is likely to be the worst documentation you have ever read, so do not hesitate to
2018-11-10 10:00:20 +00:00
[report ](https://github.com/teamnewpipe/documentation/issues ) if
2018-12-12 02:14:05 +00:00
you find any spelling errors, incomplete parts or you simply don't understand something. We are an open community
2018-11-10 10:00:20 +00:00
and are open for everyone to help :)
2018-02-22 16:11:19 +00:00
## Setup your dev environment
First and foremost you need to meet certain conditions in order to write your own service.
### What you need to know
- Basic understanding of __ [git ](https://try.github.io )__
2018-11-03 16:03:39 +00:00
- Good __ [Java ](https://whatpixel.com/best-java-books/ )__ knowledge
2018-02-22 16:11:19 +00:00
- Good understanding of __ [web technology ](https://www.w3schools.com/ )__
2018-12-12 02:14:05 +00:00
- Basic understanding of __ [unit testing ](https://www.vogella.com/tutorials/JUnit/article.html )__ and __ [JUnit ](https://junit.org/ )__
2018-02-22 16:11:19 +00:00
- Flawless understanding of how to [contribute ](https://github.com/TeamNewPipe/NewPipe/blob/dev/.github/CONTRIBUTING.md#code-contribution ) to the __NewPipe project__
### What you need to have
- A dev environment/ide that supports:
- __[git](https://git-scm.com/downloads/guis)__
- __[java 8](https://www.java.com/en/download/faq/java8.xml)__
- __[gradle](https://gradle.org/)__
2018-04-09 10:20:31 +00:00
- __[unit testing](https://junit.org/junit5/)__
2018-09-15 19:01:28 +00:00
- I highly recommend [IDEA Community ](https://www.jetbrains.com/idea/ ) since it has everything we need.
- A __ [Github ](https://github.com/ )__ account
- A lot of patience and excitement ;D
2018-02-22 16:11:19 +00:00
After making sure all these conditions are provided fork the [NewPipeExtractor ](https://github.com/TeamNewPipe/NewPipeExtractor ),
using the [fork button ](https://github.com/TeamNewPipe/NewPipeExtractor#fork-destination-box ).
This way you have your own working repository. Now clone this repository into your local folder in which you want to work in.
2018-09-15 19:01:28 +00:00
Next import the cloned project into your [IDE ](https://www.jetbrains.com/help/idea/configuring-projects.html#importing-project )
2018-02-22 16:11:19 +00:00
and [run ](https://www.jetbrains.com/help/idea/performing-tests.html ) it.
If all the checks are green you did everything right, and you are good to go to move on to the next chapter.
2018-08-21 14:45:45 +00:00
#### Running test in Android Studio
Go to _run_ > _edit configurations_ > _add new configuration_ and select "Gradle".
As Gradle Project, select NewPipeExtractor. As task add "test". Now save and you should be able to run.
2018-11-16 18:23:01 +00:00
![tests passed on idea ](img/prepare_tests_passed.png )
2018-04-08 20:57:48 +00:00
# Inclusion criteria for services
After creating you own service you will need to submit it to our [NewPipeExtractor ](https://github.com/teamnewpipe/newpipeextractor )
2018-04-08 21:02:12 +00:00
repository. However in order to include your changes you need to follow these rules:
2018-04-08 20:57:48 +00:00
1. Stick to our [Code contribution guidelines ](https://github.com/TeamNewPipe/NewPipe/blob/dev/.github/CONTRIBUTING.md#code-contribution )
2. Do not send services that present content we [don't allow ](#not-allowed-content ) on NewPipe.
3. You need to be willing to keep on maintaining your service after submission.
4. Be patient and do the requested changes when one of our maintainers rejects your code.
## Allowed Content
- Basically anything except [NOT allowed content ](#not-allowed-content ).
- Any kind of porn/NSFW that is allowed according to the [US Porn act ](https://www.justice.gov/archive/opa/pr/2003/April/03_ag_266.htm ).
2018-12-12 02:14:05 +00:00
- Advertisement (may be handled specially though)
2018-04-08 20:57:48 +00:00
## NOT allowed Content
2018-12-12 02:14:05 +00:00
- NSFL (Not Safe For Life)
2018-04-08 20:57:48 +00:00
- Porn that is not allowed according to [US Porn act ](https://www.justice.gov/archive/opa/pr/2003/April/03_ag_266.htm ).
- Any form of violence
- Child pornography
- Media that harms others
2018-05-14 11:30:23 +00:00
- Media that violates human rights
2018-04-08 20:57:48 +00:00
- Copyright infringement/pirated media