<commit_before>From f5b593bf418986576c964147923f5d429affc074 Mon Sep 17 00:00:00 2001
From: Tux <<EMAIL>>
Date: Thu, 19 May 2016 11:34:52 -0700
Subject: [PATCH] Fetch modules from the Waterfall CI

Don't fetch from the BungeeCord CI, as that only has their modules

diff --git a/proxy/src/main/java/net/md_5/bungee/module/JenkinsModuleSource.java b/proxy/src/main/java/net/md_5/bungee/module/JenkinsModuleSource.java
index 2536435c..6eb10df7 100644
--- a/proxy/src/main/java/net/md_5/bungee/module/JenkinsModuleSource.java
+++ b/proxy/src/main/java/net/md_5/bungee/module/JenkinsModuleSource.java
@@ -1,10 +1,11 @@
 package net.md_5.bungee.module;
 
-import com.google.common.io.ByteStreams;
-import com.google.common.io.Files;
 import java.io.IOException;
 import java.net.URL;
 import java.net.URLConnection;
+import java.nio.file.Files;
+import java.nio.file.StandardCopyOption;
+
 import lombok.Data;
 import net.md_5.bungee.Util;
 
@@ -18,13 +19,18 @@ public class JenkinsModuleSource implements ModuleSource
         System.out.println( "Attempting to Jenkins download module " + module.getName() + " v" + version.getBuild() );
         try
         {
+<<<<<<< HEAD
             URL website = new URL( "https://ci.md-5.net/job/BungeeCord/" + version.getBuild() + "/artifact/module/" + module.getName().replace( '_', '-' ) + "/target/" + module.getName() + ".jar" );
+=======
+            URL website = new URL( "https://ci.destroystokyo.com/job/Waterfall/" + version.getBuild() + "/artifact/Waterfall-Proxy/module/" + module.getName().replace( '_', '-' ) + "/target/" + module.getName() + ".jar" );
+>>>>>>> Fetch modules from the Waterfall CI
             URLConnection con = website.openConnection();
             // 15 second timeout at various stages
             con.setConnectTimeout( 15000 );
             con.setReadTimeout( 15000 );
+            con.setRequestProperty( "User-Agent", "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/47.0.2526.106 Safari/537.36" );
 
-            Files.write( ByteStreams.toByteArray( con.getInputStream() ), module.getFile() );
+            Files.copy( con.getInputStream(), module.getFile().toPath(), StandardCopyOption.REPLACE_EXISTING );
             System.out.println( "Download complete" );
         } catch ( IOException ex )
         {
-- 
2.11.1
<commit_msg>This commit is dedicated to JetBrains<commit_after>From 4a3bbce9c7aece2f8f6121dee46c24a94a5eb2de Mon Sep 17 00:00:00 2001
From: Tux <<EMAIL>>
Date: Thu, 19 May 2016 11:34:52 -0700
Subject: [PATCH] Fetch modules from the Waterfall CI

Don't fetch from the BungeeCord CI, as that only has their modules

diff --git a/proxy/src/main/java/net/md_5/bungee/module/JenkinsModuleSource.java b/proxy/src/main/java/net/md_5/bungee/module/JenkinsModuleSource.java
index 2536435c..11d9823f 100644
--- a/proxy/src/main/java/net/md_5/bungee/module/JenkinsModuleSource.java
+++ b/proxy/src/main/java/net/md_5/bungee/module/JenkinsModuleSource.java
@@ -1,12 +1,13 @@
 package net.md_5.bungee.module;
 
-import com.google.common.io.ByteStreams;
-import com.google.common.io.Files;
+import lombok.Data;
+import net.md_5.bungee.Util;
+
 import java.io.IOException;
 import java.net.URL;
 import java.net.URLConnection;
-import lombok.Data;
-import net.md_5.bungee.Util;
+import java.nio.file.Files;
+import java.nio.file.StandardCopyOption;
 
 @Data
 public class JenkinsModuleSource implements ModuleSource
@@ -18,13 +19,14 @@ public class JenkinsModuleSource implements ModuleSource
         System.out.println( "Attempting to Jenkins download module " + module.getName() + " v" + version.getBuild() );
         try
         {
-            URL website = new URL( "https://ci.md-5.net/job/BungeeCord/" + version.getBuild() + "/artifact/module/" + module.getName().replace( '_', '-' ) + "/target/" + module.getName() + ".jar" );
+            URL website = new URL( "https://ci.destroystokyo.com/job/Waterfall/" + version.getBuild() + "/artifact/Waterfall-Proxy/module/" + module.getName().replace( '_', '-' ) + "/target/" + module.getName() + ".jar" );
             URLConnection con = website.openConnection();
             // 15 second timeout at various stages
             con.setConnectTimeout( 15000 );
             con.setReadTimeout( 15000 );
+            con.setRequestProperty( "User-Agent", "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/47.0.2526.106 Safari/537.36" );
 
-            Files.write( ByteStreams.toByteArray( con.getInputStream() ), module.getFile() );
+            Files.copy( con.getInputStream(), module.getFile().toPath(), StandardCopyOption.REPLACE_EXISTING );
             System.out.println( "Download complete" );
         } catch ( IOException ex )
         {
-- 
2.11.1

{'fraction_non_alphanumeric': 0.15029387069689337, 'fraction_numerical': 0.05667506297229219, 'mean_word_length': 3.300541516245487, 'pattern_counts': {'":': 0, '<': 14, '<?xml version=': 0, '>': 14, 'https://': 4, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 4, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5325171', 'n_tokens_mistral': 1782, 'n_tokens_neox': 1582, 'n_words': 316}