Implemented Pinboard.in integration.
This commit is contained in:
parent
16953c8f98
commit
73dbd6c0d8
12 changed files with 214 additions and 157 deletions
166
.idea/modules/mobibot.iml
generated
166
.idea/modules/mobibot.iml
generated
|
@ -1,5 +1,5 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<module external.linked.project.id="mobibot" external.linked.project.path="$MODULE_DIR$/../.." external.root.project.path="$MODULE_DIR$/../.." external.system.id="GRADLE" external.system.module.group="" external.system.module.version="0.7.1-beta+018" type="JAVA_MODULE" version="4">
|
||||
<module external.linked.project.id="mobibot" external.linked.project.path="$MODULE_DIR$/../.." external.root.project.path="$MODULE_DIR$/../.." external.system.id="GRADLE" external.system.module.group="" external.system.module.version="0.7.1-beta+020" type="JAVA_MODULE" version="4">
|
||||
<component name="NewModuleRootManager">
|
||||
<output url="file://$MODULE_DIR$/../../build/classes/main" />
|
||||
<output-test url="file://$MODULE_DIR$/../../build/classes/test" />
|
||||
|
@ -18,62 +18,40 @@
|
|||
<orderEntry type="inheritedJdk" />
|
||||
<orderEntry type="sourceFolder" forTests="false" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: log4j:log4j:1.2.17" level="project" />
|
||||
<orderEntry type="module-library" scope="TEST">
|
||||
<library name="Gradle: owm-japis-2.5.0.5">
|
||||
<CLASSES>
|
||||
<root url="jar://$MODULE_DIR$/../../lib/owm-japis-2.5.0.5.jar!/" />
|
||||
</CLASSES>
|
||||
<JAVADOC />
|
||||
<SOURCES />
|
||||
</library>
|
||||
</orderEntry>
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: org.slf4j:slf4j-api:1.7.25" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: org.jdom:jdom2:2.0.6" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: com.rometools:rome-utils:1.7.1" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: net.sf.delicious-java:delicious:1.14" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: org.twitter4j:twitter4j-core:4.0.6" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: net.objecthunter:exp4j:0.4.8" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: org.ostermiller:utils:1.07.00" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: org.json:json:20160810" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: org.slf4j:slf4j-log4j12:1.7.25" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: com.rometools:rome:1.7.1" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: org.jsoup:jsoup:1.10.2" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: oro:oro:2.0.8" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: commons-httpclient:commons-httpclient:3.1" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: commons-cli:commons-cli:1.4" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: commons-net:commons-net:3.6" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: commons-logging:commons-logging:1.2" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: commons-codec:commons-codec:1.10" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: pircbot:pircbot:1.5.0" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: log4j:log4j:1.2.17" level="project" />
|
||||
<orderEntry type="module-library" scope="RUNTIME">
|
||||
<library name="Gradle: owm-japis-2.5.0.5">
|
||||
<CLASSES>
|
||||
<root url="jar://$MODULE_DIR$/../../lib/owm-japis-2.5.0.5.jar!/" />
|
||||
</CLASSES>
|
||||
<JAVADOC />
|
||||
<SOURCES />
|
||||
</library>
|
||||
</orderEntry>
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: org.slf4j:slf4j-api:1.7.25" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: org.jdom:jdom2:2.0.6" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: com.rometools:rome-utils:1.7.1" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: net.sf.delicious-java:delicious:1.14" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: org.twitter4j:twitter4j-core:4.0.6" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: net.objecthunter:exp4j:0.4.8" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: org.ostermiller:utils:1.07.00" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: org.json:json:20160810" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: org.slf4j:slf4j-log4j12:1.7.25" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: com.rometools:rome:1.7.1" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: org.jsoup:jsoup:1.10.2" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: oro:oro:2.0.8" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: commons-httpclient:commons-httpclient:3.1" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: commons-cli:commons-cli:1.4" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: commons-net:commons-net:3.6" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: commons-logging:commons-logging:1.2" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: commons-codec:commons-codec:1.10" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: pircbot:pircbot:1.5.0" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: log4j:log4j:1.2.17" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: com.squareup.okio:okio:1.13.0" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: org.jetbrains:annotations:13.0" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: com.squareup.okhttp3:okhttp:3.8.0" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: org.jetbrains.kotlin:kotlin-stdlib:1.1.2-3" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: net.thauvin.erik:pinboard-poster:0.9.0" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: com.squareup.okio:okio:1.13.0" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: org.jetbrains:annotations:13.0" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: com.squareup.okhttp3:okhttp:3.8.0" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: org.jetbrains.kotlin:kotlin-stdlib:1.1.2-3" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: net.thauvin.erik:pinboard-poster:0.9.0" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: com.squareup.okio:okio:1.13.0" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: org.jetbrains:annotations:13.0" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: com.squareup.okhttp3:okhttp:3.8.0" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: org.jetbrains.kotlin:kotlin-stdlib:1.1.2-3" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: net.thauvin.erik:pinboard-poster:0.9.0" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: pircbot:pircbot:1.5.0" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: commons-codec:commons-codec:1.10" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: commons-logging:commons-logging:1.2" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: commons-net:commons-net:3.6" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: commons-cli:commons-cli:1.4" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: commons-httpclient:commons-httpclient:3.1" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: oro:oro:2.0.8" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: org.jsoup:jsoup:1.10.2" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: com.rometools:rome:1.7.1" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: org.slf4j:slf4j-log4j12:1.7.25" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: org.json:json:20160810" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: org.ostermiller:utils:1.07.00" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: net.objecthunter:exp4j:0.4.8" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: org.twitter4j:twitter4j-core:4.0.6" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: net.thauvin.erik:semver:1.0.0" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: com.rometools:rome-utils:1.7.1" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: org.jdom:jdom2:2.0.6" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: com.github.spullara.mustache.java:compiler:0.9.4" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: org.slf4j:slf4j-api:1.7.25" level="project" />
|
||||
<orderEntry type="module-library" scope="PROVIDED">
|
||||
<library name="Gradle: owm-japis-2.5.0.5">
|
||||
<CLASSES>
|
||||
|
@ -83,25 +61,59 @@
|
|||
<SOURCES />
|
||||
</library>
|
||||
</orderEntry>
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: org.slf4j:slf4j-api:1.7.25" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: com.github.spullara.mustache.java:compiler:0.9.4" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: org.jdom:jdom2:2.0.6" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: com.rometools:rome-utils:1.7.1" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: net.thauvin.erik:semver:1.0.0" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: net.sf.delicious-java:delicious:1.14" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: org.twitter4j:twitter4j-core:4.0.6" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: net.objecthunter:exp4j:0.4.8" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: org.ostermiller:utils:1.07.00" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: org.json:json:20160810" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: org.slf4j:slf4j-log4j12:1.7.25" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: com.rometools:rome:1.7.1" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: org.jsoup:jsoup:1.10.2" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: oro:oro:2.0.8" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: commons-httpclient:commons-httpclient:3.1" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: commons-cli:commons-cli:1.4" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: commons-net:commons-net:3.6" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: commons-logging:commons-logging:1.2" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: commons-codec:commons-codec:1.10" level="project" />
|
||||
<orderEntry type="library" scope="PROVIDED" name="Gradle: pircbot:pircbot:1.5.0" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: log4j:log4j:1.2.17" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: pircbot:pircbot:1.5.0" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: commons-codec:commons-codec:1.10" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: commons-logging:commons-logging:1.2" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: commons-net:commons-net:3.6" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: commons-cli:commons-cli:1.4" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: commons-httpclient:commons-httpclient:3.1" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: oro:oro:2.0.8" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: org.jsoup:jsoup:1.10.2" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: com.rometools:rome:1.7.1" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: org.slf4j:slf4j-log4j12:1.7.25" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: org.json:json:20160810" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: org.ostermiller:utils:1.07.00" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: net.objecthunter:exp4j:0.4.8" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: org.twitter4j:twitter4j-core:4.0.6" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: com.rometools:rome-utils:1.7.1" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: org.jdom:jdom2:2.0.6" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Gradle: org.slf4j:slf4j-api:1.7.25" level="project" />
|
||||
<orderEntry type="module-library" scope="RUNTIME">
|
||||
<library name="Gradle: owm-japis-2.5.0.5">
|
||||
<CLASSES>
|
||||
<root url="jar://$MODULE_DIR$/../../lib/owm-japis-2.5.0.5.jar!/" />
|
||||
</CLASSES>
|
||||
<JAVADOC />
|
||||
<SOURCES />
|
||||
</library>
|
||||
</orderEntry>
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: log4j:log4j:1.2.17" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: pircbot:pircbot:1.5.0" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: commons-codec:commons-codec:1.10" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: commons-logging:commons-logging:1.2" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: commons-net:commons-net:3.6" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: commons-cli:commons-cli:1.4" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: commons-httpclient:commons-httpclient:3.1" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: oro:oro:2.0.8" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: org.jsoup:jsoup:1.10.2" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: com.rometools:rome:1.7.1" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: org.slf4j:slf4j-log4j12:1.7.25" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: org.json:json:20160810" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: org.ostermiller:utils:1.07.00" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: net.objecthunter:exp4j:0.4.8" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: org.twitter4j:twitter4j-core:4.0.6" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: com.rometools:rome-utils:1.7.1" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: org.jdom:jdom2:2.0.6" level="project" />
|
||||
<orderEntry type="library" scope="TEST" name="Gradle: org.slf4j:slf4j-api:1.7.25" level="project" />
|
||||
<orderEntry type="module-library" scope="TEST">
|
||||
<library name="Gradle: owm-japis-2.5.0.5">
|
||||
<CLASSES>
|
||||
<root url="jar://$MODULE_DIR$/../../lib/owm-japis-2.5.0.5.jar!/" />
|
||||
</CLASSES>
|
||||
<JAVADOC />
|
||||
<SOURCES />
|
||||
</library>
|
||||
</orderEntry>
|
||||
</component>
|
||||
</module>
|
|
@ -70,7 +70,7 @@ dependencies {
|
|||
compile 'net.objecthunter:exp4j:0.4.8'
|
||||
|
||||
compile 'org.twitter4j:twitter4j-core:4.0.6'
|
||||
compile 'net.sf.delicious-java:delicious:1.14'
|
||||
compile 'net.thauvin.erik:pinboard-poster:0.9.1'
|
||||
|
||||
compile files('lib/owm-japis-2.5.0.5.jar')
|
||||
|
||||
|
|
|
@ -14,6 +14,7 @@ import java.io.FileInputStream
|
|||
import java.util.*
|
||||
|
||||
val bs = buildScript {
|
||||
repos(localMaven())
|
||||
}
|
||||
|
||||
val mainClassName = "net.thauvin.erik.mobibot.Mobibot"
|
||||
|
@ -72,7 +73,7 @@ val p = project {
|
|||
compile("net.objecthunter:exp4j:0.4.8")
|
||||
|
||||
compile("org.twitter4j:twitter4j-core:4.0.6")
|
||||
compile("net.sf.delicious-java:delicious:1.14")
|
||||
compile("net.thauvin.erik:pinboard-poster:0.9.1")
|
||||
|
||||
compile(file("lib/owm-japis-2.5.0.5.jar"))
|
||||
|
||||
|
|
42
mobibot.ipr
42
mobibot.ipr
|
@ -357,6 +357,24 @@
|
|||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/com.rometools/rome/1.7.1/2bab37f921df082d245d440f96dc63a69cb5f67/rome-1.7.1-sources.jar!/" />
|
||||
</SOURCES>
|
||||
</library>
|
||||
<library name="Gradle: com.squareup.okhttp3:okhttp:3.8.0">
|
||||
<CLASSES>
|
||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/com.squareup.okhttp3/okhttp/3.8.0/5a11f020cce2d11eb71ba916700600e18c4547e7/okhttp-3.8.0.jar!/" />
|
||||
</CLASSES>
|
||||
<JAVADOC />
|
||||
<SOURCES>
|
||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/com.squareup.okhttp3/okhttp/3.8.0/db21293949e200f08d5325e8a8eefdcc9134b752/okhttp-3.8.0-sources.jar!/" />
|
||||
</SOURCES>
|
||||
</library>
|
||||
<library name="Gradle: com.squareup.okio:okio:1.13.0">
|
||||
<CLASSES>
|
||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/com.squareup.okio/okio/1.13.0/a9283170b7305c8d92d25aff02a6ab7e45d06cbe/okio-1.13.0.jar!/" />
|
||||
</CLASSES>
|
||||
<JAVADOC />
|
||||
<SOURCES>
|
||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/com.squareup.okio/okio/1.13.0/f4c91e12121af963e3ef76e81c82aa75ba6e8533/okio-1.13.0-sources.jar!/" />
|
||||
</SOURCES>
|
||||
</library>
|
||||
<library name="Gradle: commons-cli:commons-cli:1.4">
|
||||
<CLASSES>
|
||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/commons-cli/commons-cli/1.4/c51c00206bb913cd8612b24abd9fa98ae89719b1/commons-cli-1.4.jar!/" />
|
||||
|
@ -420,13 +438,13 @@
|
|||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.objecthunter/exp4j/0.4.8/8d86f148ff1f0d5b624eae9bb0882198ab5cd07/exp4j-0.4.8-sources.jar!/" />
|
||||
</SOURCES>
|
||||
</library>
|
||||
<library name="Gradle: net.sf.delicious-java:delicious:1.14">
|
||||
<library name="Gradle: net.thauvin.erik:pinboard-poster:0.9.0">
|
||||
<CLASSES>
|
||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.sf.delicious-java/delicious/1.14/6fdcbf3ef291e2a2352fc4c27fe033f02206ee1a/delicious-1.14.jar!/" />
|
||||
<root url="jar://$MAVEN_REPOSITORY$/net/thauvin/erik/pinboard-poster/0.9.0/pinboard-poster-0.9.0.jar!/" />
|
||||
</CLASSES>
|
||||
<JAVADOC />
|
||||
<SOURCES>
|
||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/net.sf.delicious-java/delicious/1.14/af3389b4f23bb9ac23552bff5ae6ed917df36192/delicious-1.14-sources.jar!/" />
|
||||
<root url="jar://$MAVEN_REPOSITORY$/net/thauvin/erik/pinboard-poster/0.9.0/pinboard-poster-0.9.0-sources.jar!/" />
|
||||
</SOURCES>
|
||||
</library>
|
||||
<library name="Gradle: net.thauvin.erik:semver:1.0.0">
|
||||
|
@ -447,6 +465,24 @@
|
|||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jdom/jdom2/2.0.6/3dcf8ba7582eeac3b67ed5155ee3659e16c8dadc/jdom2-2.0.6-sources.jar!/" />
|
||||
</SOURCES>
|
||||
</library>
|
||||
<library name="Gradle: org.jetbrains.kotlin:kotlin-stdlib:1.1.2-3">
|
||||
<CLASSES>
|
||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-stdlib/1.1.2-3/552a40eb47669b78f0f194d526cb21b3aa1f8319/kotlin-stdlib-1.1.2-3.jar!/" />
|
||||
</CLASSES>
|
||||
<JAVADOC />
|
||||
<SOURCES>
|
||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-stdlib/1.1.2-3/7502cd343c8990a77aabb7cf41bd7e9f186c06cc/kotlin-stdlib-1.1.2-3-sources.jar!/" />
|
||||
</SOURCES>
|
||||
</library>
|
||||
<library name="Gradle: org.jetbrains:annotations:13.0">
|
||||
<CLASSES>
|
||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains/annotations/13.0/919f0dfe192fb4e063e7dacadee7f8bb9a2672a9/annotations-13.0.jar!/" />
|
||||
</CLASSES>
|
||||
<JAVADOC />
|
||||
<SOURCES>
|
||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.jetbrains/annotations/13.0/5991ca87ef1fb5544943d9abc5a9a37583fabe03/annotations-13.0-sources.jar!/" />
|
||||
</SOURCES>
|
||||
</library>
|
||||
<library name="Gradle: org.json:json:20160810">
|
||||
<CLASSES>
|
||||
<root url="jar://$USER_HOME$/.gradle/caches/modules-2/files-2.1/org.json/json/20160810/aca5eb39e2a12fddd6c472b240afe9ebea3a6733/json-20160810.jar!/" />
|
||||
|
|
|
@ -11,8 +11,5 @@ log4j.appender.stderr.target=System.err
|
|||
log4j.logger.org.apache.commons.httpclient=FATAL
|
||||
log4j.logger.httpclient.wire=FATAL
|
||||
|
||||
# Print only messages of priority FATAL or above in the package net.sf.jweather
|
||||
log4j.category.net.sf.jweather=FATAL
|
||||
|
||||
# Print only messages of priority FATAL or above in the package net.thauvin.erik.mobibot
|
||||
log4j.category.net.thauvin.erik.mobibot=FATAL
|
||||
|
|
|
@ -21,11 +21,9 @@ tell-max-days=5
|
|||
tell-max-size=50
|
||||
|
||||
#
|
||||
# Credentials for: http://del.icio.us/
|
||||
# Credentials for: http://pinboard.in/
|
||||
#
|
||||
#delicious-user=
|
||||
#delicious-pwd=
|
||||
#declicious-api-endpoint=https://api.pinboard.in/v1/
|
||||
#pinboard-api-token=user\:TOKEN
|
||||
|
||||
|
||||
#
|
||||
|
|
|
@ -18,12 +18,12 @@ public final class ReleaseInfo {
|
|||
|
||||
public final static String PROJECT = "mobibot";
|
||||
public final static LocalDateTime BUILDDATE =
|
||||
LocalDateTime.ofInstant(Instant.ofEpochMilli(1494906988487L), ZoneId.systemDefault());
|
||||
LocalDateTime.ofInstant(Instant.ofEpochMilli(1495067438992L), ZoneId.systemDefault());
|
||||
public final static int MAJOR = 0;
|
||||
public final static int MINOR = 7;
|
||||
public final static int PATCH = 1;
|
||||
public final static String PRERELEASE = "beta";
|
||||
public final static String BUILDMETA = "020";
|
||||
public final static String BUILDMETA = "021";
|
||||
|
||||
/**
|
||||
* The full version string.
|
||||
|
|
|
@ -206,11 +206,11 @@ public class EntryLink implements Serializable {
|
|||
}
|
||||
|
||||
/**
|
||||
* Returns the tags formatted for del.icio.us.
|
||||
* Returns the tags formatted for pinboard.in
|
||||
*
|
||||
* @return The tags as a comma-delimited string.
|
||||
*/
|
||||
public final String getDeliciousTags() {
|
||||
public final String getPinboardTags() {
|
||||
final StringBuilder tags = new StringBuilder(nick);
|
||||
|
||||
for (final Object tag : this.tags) {
|
||||
|
|
|
@ -32,7 +32,6 @@
|
|||
package net.thauvin.erik.mobibot;
|
||||
|
||||
import com.rometools.rome.io.FeedException;
|
||||
import del.icio.us.DeliciousConstants;
|
||||
import net.thauvin.erik.mobibot.modules.*;
|
||||
import net.thauvin.erik.semver.Version;
|
||||
import org.apache.commons.cli.*;
|
||||
|
@ -167,22 +166,16 @@ public class Mobibot extends PircBot {
|
|||
|
||||
// The default tags/categories.
|
||||
private String defaultTags = "";
|
||||
|
||||
// The del.icio.us posts handler.
|
||||
private DeliciousPoster delicious = null;
|
||||
|
||||
// The feed URL.
|
||||
private String feedURL = "";
|
||||
|
||||
// The ident message.
|
||||
private String identMsg = "";
|
||||
|
||||
// The ident nick.
|
||||
private String identNick = "";
|
||||
|
||||
// The NickServ ident password.
|
||||
private String identPwd = "";
|
||||
|
||||
// The pinboard posts handler.
|
||||
private Pinboard pinboard = null;
|
||||
// Today's date.
|
||||
private String today = Utils.today();
|
||||
|
||||
|
@ -356,10 +349,8 @@ public class Mobibot extends PircBot {
|
|||
final String identPwd = p.getProperty("ident", "");
|
||||
final String tags = p.getProperty("tags", "");
|
||||
|
||||
// Get the del.icio.us properties
|
||||
final String dname = p.getProperty("delicious-user");
|
||||
final String dpwd = p.getProperty("delicious-pwd");
|
||||
final String dapi = p.getProperty("declicious-api-endpoint", DeliciousConstants.API_ENDPOINT);
|
||||
// Get the pinboard properties
|
||||
final String pinApiToken = p.getProperty("pinboard-api-token");
|
||||
|
||||
// Create the bot
|
||||
final Mobibot bot = new Mobibot(server, port, nickname, channel, logsDir);
|
||||
|
@ -380,8 +371,8 @@ public class Mobibot extends PircBot {
|
|||
bot.setFeedURL(feedURL);
|
||||
bot.setBacklogsUrl(backlogsURL);
|
||||
|
||||
// Set the del.icio.us authentication
|
||||
bot.setDeliciousAuth(dapi, dname, dpwd);
|
||||
// Set the pinboard authentication
|
||||
bot.setPinboardAuth(pinApiToken);
|
||||
|
||||
// Load the modules properties
|
||||
MODULES.stream().filter(AbstractModule::hasProperties).forEach(
|
||||
|
@ -1044,8 +1035,8 @@ public class Mobibot extends PircBot {
|
|||
final EntryLink entry = entries.get(index);
|
||||
send(channel, Utils.buildLink(index, entry));
|
||||
|
||||
if (delicious != null) {
|
||||
delicious.addPost(entry);
|
||||
if (pinboard != null) {
|
||||
pinboard.addPost(entry);
|
||||
}
|
||||
|
||||
saveEntries(isBackup);
|
||||
|
@ -1152,8 +1143,8 @@ public class Mobibot extends PircBot {
|
|||
final EntryLink entry = entries.get(index);
|
||||
|
||||
if (entry.getLogin().equals(login) || isOp(sender)) {
|
||||
if (delicious != null) {
|
||||
delicious.deletePost(entry);
|
||||
if (pinboard != null) {
|
||||
pinboard.deletePost(entry);
|
||||
}
|
||||
|
||||
entries.remove(index);
|
||||
|
@ -1169,8 +1160,8 @@ public class Mobibot extends PircBot {
|
|||
final EntryLink entry = entries.get(index);
|
||||
entry.setTitle(cmd.substring(1).trim());
|
||||
|
||||
if (delicious != null) {
|
||||
delicious.updatePost(entry.getLink(), entry);
|
||||
if (pinboard != null) {
|
||||
pinboard.updatePost(entry.getLink(), entry);
|
||||
}
|
||||
|
||||
send(channel, Utils.buildLink(index, entry));
|
||||
|
@ -1189,8 +1180,8 @@ public class Mobibot extends PircBot {
|
|||
|
||||
entry.setLink(link);
|
||||
|
||||
if (delicious != null) {
|
||||
delicious.updatePost(oldLink, entry);
|
||||
if (pinboard != null) {
|
||||
pinboard.updatePost(oldLink, entry);
|
||||
}
|
||||
|
||||
send(channel, Utils.buildLink(index, entry));
|
||||
|
@ -1239,8 +1230,8 @@ public class Mobibot extends PircBot {
|
|||
if (entry.getLogin().equals(login) || isOp(sender)) {
|
||||
entry.setTags(cmd);
|
||||
|
||||
if (delicious != null) {
|
||||
delicious.updatePost(entry.getLink(), entry);
|
||||
if (pinboard != null) {
|
||||
pinboard.updatePost(entry.getLink(), entry);
|
||||
}
|
||||
|
||||
send(channel, Utils.buildTags(index, entry));
|
||||
|
@ -1439,7 +1430,7 @@ public class Mobibot extends PircBot {
|
|||
private void recapResponse(final String sender, final boolean isPrivate) {
|
||||
if (this.recap.size() > 0) {
|
||||
for (final String recap : this.recap) {
|
||||
send(sender, recap, isPrivate);
|
||||
send(sender, recap, isPrivate);
|
||||
}
|
||||
} else {
|
||||
send(sender, "Sorry, nothing to recap.", true);
|
||||
|
@ -1491,19 +1482,6 @@ public class Mobibot extends PircBot {
|
|||
send(sender, message, false);
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the del.icio.us authentication.
|
||||
*
|
||||
* @param apiEndPoint The API end point.
|
||||
* @param username The del.icio.us user name.
|
||||
* @param password The del.icio.us password.
|
||||
*/
|
||||
private void setDeliciousAuth(final String apiEndPoint, final String username, final String password) {
|
||||
if (Utils.isValidString(username) && Utils.isValidString(password)) {
|
||||
delicious = new DeliciousPoster(apiEndPoint, username, password, ircServer);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the feed URL.
|
||||
*
|
||||
|
@ -1541,6 +1519,17 @@ public class Mobibot extends PircBot {
|
|||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the pinboard authentication.
|
||||
*
|
||||
* @param apiToken The API token
|
||||
*/
|
||||
private void setPinboardAuth(final String apiToken) {
|
||||
if (Utils.isValidString(apiToken)) {
|
||||
pinboard = new Pinboard(this, apiToken, ircServer);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the default tags/categories.
|
||||
*
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* DeliciousPoster.java
|
||||
* Pinboard.java
|
||||
*
|
||||
* Copyright (c) 2004-2017, Erik C. Thauvin (erik@thauvin.net)
|
||||
* All rights reserved.
|
||||
|
@ -31,32 +31,46 @@
|
|||
*/
|
||||
package net.thauvin.erik.mobibot;
|
||||
|
||||
import del.icio.us.Delicious;
|
||||
import net.thauvin.erik.pinboard.PinboardPoster;
|
||||
|
||||
import javax.swing.*;
|
||||
import java.time.ZoneId;
|
||||
import java.time.ZonedDateTime;
|
||||
import java.time.format.DateTimeFormatter;
|
||||
import java.util.Date;
|
||||
import java.util.logging.ConsoleHandler;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
/**
|
||||
* The class to handle posts to del.icio.us.
|
||||
* The class to handle posts to pinbard.in.
|
||||
*
|
||||
* @author <a href="http://erik.thauvin.net/" target="_blank">Erik C. Thauvin</a>
|
||||
* @created Mar 5, 2005
|
||||
* @created 2017-05-17
|
||||
* @since 1.0
|
||||
*/
|
||||
class DeliciousPoster {
|
||||
private final Delicious delicious;
|
||||
class Pinboard {
|
||||
private final String ircServer;
|
||||
private final PinboardPoster pinboard;
|
||||
|
||||
/**
|
||||
* Creates a new {@link DeliciousPoster} instance.
|
||||
* Creates a new {@link Pinboard} instance.
|
||||
*
|
||||
* @param apiEndPoint The API end point.
|
||||
* @param username The del.icio.us user name.
|
||||
* @param password The del.icio.us password.
|
||||
* @param bot The bot's instance.
|
||||
* @param apiToken The API end point.
|
||||
* @param ircServer The IRC server.
|
||||
*/
|
||||
public DeliciousPoster(final String apiEndPoint, final String username, final String password, final String ircServer) {
|
||||
delicious = new Delicious(username, password, apiEndPoint);
|
||||
public Pinboard(final Mobibot bot, final String apiToken, final String ircServer) {
|
||||
pinboard = new PinboardPoster(apiToken);
|
||||
this.ircServer = ircServer;
|
||||
|
||||
if (bot.getLogger().isDebugEnabled()) {
|
||||
final ConsoleHandler consoleHandler = new ConsoleHandler();
|
||||
consoleHandler.setLevel(Level.FINE);
|
||||
final Logger logger = pinboard.getLogger();
|
||||
logger.addHandler(consoleHandler);
|
||||
logger.setLevel(Level.FINE);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -69,11 +83,11 @@ class DeliciousPoster {
|
|||
@Override
|
||||
protected Boolean doInBackground()
|
||||
throws Exception {
|
||||
return delicious.addPost(entry.getLink(),
|
||||
return pinboard.addPin(entry.getLink(),
|
||||
entry.getTitle(),
|
||||
postedBy(entry),
|
||||
entry.getDeliciousTags(),
|
||||
entry.getDate());
|
||||
entry.getPinboardTags(),
|
||||
formatDate(entry.getDate()));
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -92,13 +106,23 @@ class DeliciousPoster {
|
|||
@Override
|
||||
protected Boolean doInBackground()
|
||||
throws Exception {
|
||||
return delicious.deletePost(link);
|
||||
return pinboard.deletePin(link);
|
||||
}
|
||||
};
|
||||
|
||||
worker.execute();
|
||||
}
|
||||
|
||||
/**
|
||||
* Format a date to a UTC timestamp.
|
||||
*
|
||||
* @param date The date.
|
||||
* @return The date in {@link DateTimeFormatter#ISO_INSTANT} format.
|
||||
*/
|
||||
private String formatDate(final Date date) {
|
||||
return ZonedDateTime.ofInstant(date.toInstant(), ZoneId.systemDefault()).format(DateTimeFormatter.ISO_INSTANT);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns he del.icio.us extended attribution line.
|
||||
*
|
||||
|
@ -121,19 +145,19 @@ class DeliciousPoster {
|
|||
protected Boolean doInBackground()
|
||||
throws Exception {
|
||||
if (!oldUrl.equals(entry.getLink())) {
|
||||
delicious.deletePost(oldUrl);
|
||||
pinboard.deletePin(oldUrl);
|
||||
|
||||
return delicious.addPost(entry.getLink(),
|
||||
return pinboard.addPin(entry.getLink(),
|
||||
entry.getTitle(),
|
||||
postedBy(entry),
|
||||
entry.getDeliciousTags(),
|
||||
entry.getDate());
|
||||
entry.getPinboardTags(),
|
||||
formatDate(entry.getDate()));
|
||||
} else {
|
||||
return delicious.addPost(entry.getLink(),
|
||||
return pinboard.addPin(entry.getLink(),
|
||||
entry.getTitle(),
|
||||
postedBy(entry),
|
||||
entry.getDeliciousTags(),
|
||||
entry.getDate(),
|
||||
entry.getPinboardTags(),
|
||||
formatDate(entry.getDate()),
|
||||
true,
|
||||
true);
|
||||
}
|
|
@ -140,7 +140,7 @@ final public class Utils {
|
|||
* @return The entry's tags.
|
||||
*/
|
||||
static String buildTags(final int entryIndex, final EntryLink entry) {
|
||||
return (Commands.LINK_CMD + (entryIndex + 1) + "T: " + entry.getDeliciousTags().replaceAll(",", ", "));
|
||||
return (Commands.LINK_CMD + (entryIndex + 1) + "T: " + entry.getPinboardTags().replaceAll(",", ", "));
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -5,4 +5,4 @@ version.major=0
|
|||
version.minor=7
|
||||
version.patch=1
|
||||
version.prerelease=beta
|
||||
version.buildmeta=020
|
||||
version.buildmeta=021
|
Loading…
Add table
Add a link
Reference in a new issue