Compare commits
48 Commits
Author | SHA1 | Date | |
---|---|---|---|
baec921a37 | |||
fd0bfb8b3d | |||
6ac3a2eb55 | |||
50de466282 | |||
ad61d69be0 | |||
8b1e908bc1 | |||
19fb2f5378 | |||
e0d0a537e7 | |||
b4371dad07 | |||
fbbaffddb9 | |||
7f409bfc1f | |||
bdf9ca5548 | |||
397afe0cb7 | |||
0df0a380bb | |||
10887da2f7 | |||
3da4c9ee1e | |||
c24a0acea1 | |||
41a4e895cc | |||
ba6275008a | |||
f268f3b459 | |||
eb195f7dba | |||
bbd2fdeeec | |||
ecfc447125 | |||
238f3fd839 | |||
c01312a1a5 | |||
b72dd14310 | |||
64aac910a6 | |||
246c27627b | |||
d529f353e4 | |||
89cff0c444 | |||
ff19ea685b | |||
e5f6f335ee | |||
bcfbf90be2 | |||
63922c3880 | |||
35570a119d | |||
b877b6141d | |||
62f23d360d | |||
c78614fea5 | |||
44cc27b968 | |||
274748d08b | |||
b4840b7355 | |||
6072b8552e | |||
7c0070cd15 | |||
8083c6c652 | |||
d9d13fac70 | |||
75049fa08e | |||
113caaa922 | |||
bf1b923750 |
30
.github/workflows/ant.yml
vendored
30
.github/workflows/ant.yml
vendored
@ -40,42 +40,42 @@ jobs:
|
|||||||
- name: Upload Firefox Profile Strict
|
- name: Upload Firefox Profile Strict
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: i2p.firefox.base.profile-${{ github.sha }}.zip
|
name: i2p.firefox.base.profile.zip
|
||||||
path: ./src/i2p.firefox.base.profile.zip
|
path: ./src/i2p.firefox.base.profile.zip
|
||||||
- name: Upload Firefox Profile Usability
|
- name: Upload Firefox Profile Usability
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: i2p.firefox.usability.profile-${{ github.sha }}.zip
|
name: i2p.firefox.usability.profile.zip
|
||||||
path: ./src/i2p.firefox.usability.profile.zip
|
path: ./src/i2p.firefox.usability.profile.zip
|
||||||
- name: Upload Chromium Profile Strict
|
- name: Upload Chromium Profile Strict
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: i2p.chromium.base.profile-${{ github.sha }}.zip
|
name: i2p.chromium.base.profile.zip
|
||||||
path: ./src/i2p.chromium.base.profile.zip
|
path: ./src/i2p.chromium.base.profile.zip
|
||||||
- name: Upload Chromium Profile Usability
|
- name: Upload Chromium Profile Usability
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: i2p.chromium.usability.profile-${{ github.sha }}.zip
|
name: i2p.chromium.usability.profile.zip
|
||||||
path: ./src/i2p.chromium.usability.profile.zip
|
path: ./src/i2p.chromium.usability.profile.zip
|
||||||
- name: Upload i2pfirefox.jar
|
- name: Upload i2pfirefox.jar
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: i2pfirefox-${{ github.sha }}.jar
|
name: i2pfirefox.jar
|
||||||
path: ./src/build/i2pfirefox.jar
|
path: ./src/build/i2pfirefox.jar
|
||||||
- name: Upload i2pfirefox-plugin.jar
|
- name: Upload i2pfirefox-plugin.jar
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: i2pfirefox-plugin-${{ github.sha }}.jar
|
name: i2pfirefox-plugin.jar
|
||||||
path: ./src/build/i2pfirefox-plugin.jar
|
path: ./src/build/i2pfirefox-plugin.jar
|
||||||
- name: Upload i2pbrowser.tar.gz
|
- name: Upload i2pbrowser.tar.gz
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: i2pbrowser-${{ github.sha }}.tar.gz
|
name: i2pbrowser.tar.gz
|
||||||
path: ./i2pbrowser.tar.gz
|
path: ./i2pbrowser.tar.gz
|
||||||
- name: Upload i2pbrowser.deb
|
- name: Upload i2pbrowser.deb
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: i2pbrowser_${{ github.sha }}_amd64.deb
|
name: i2pbrowser_amd64.deb
|
||||||
path: ./i2pbrowser_1.0.0_amd64.deb
|
path: ./i2pbrowser_1.0.0_amd64.deb
|
||||||
- name: build plugin with Ant
|
- name: build plugin with Ant
|
||||||
run: |
|
run: |
|
||||||
@ -84,7 +84,7 @@ jobs:
|
|||||||
- name: Upload i2pfirefox.zip (unsigned plugin)
|
- name: Upload i2pfirefox.zip (unsigned plugin)
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: i2pfirefox-${{ github.sha }}.zip
|
name: i2pfirefox.zip
|
||||||
path: ./plugin.zip
|
path: ./plugin.zip
|
||||||
|
|
||||||
|
|
||||||
@ -132,7 +132,7 @@ jobs:
|
|||||||
- name: Upload i2pbrowser.rpm
|
- name: Upload i2pbrowser.rpm
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: i2pbrowser-${{ github.sha }}.x86_64.rpm
|
name: i2pbrowser.x86_64.rpm
|
||||||
path: ./i2pbrowser-1.0.0-1.x86_64.rpm
|
path: ./i2pbrowser-1.0.0-1.x86_64.rpm
|
||||||
|
|
||||||
|
|
||||||
@ -171,7 +171,7 @@ jobs:
|
|||||||
- name: Upload Firefox Profile EXE Installer
|
- name: Upload Firefox Profile EXE Installer
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: i2pbrowser-1.0.0-${{ github.sha }}.exe
|
name: i2pbrowser-1.0.0.exe
|
||||||
path: ./i2pbrowser-1.0.0.exe
|
path: ./i2pbrowser-1.0.0.exe
|
||||||
- name: build msi with Ant
|
- name: build msi with Ant
|
||||||
run: |
|
run: |
|
||||||
@ -180,7 +180,7 @@ jobs:
|
|||||||
- name: Upload Firefox Profile MSI Installer
|
- name: Upload Firefox Profile MSI Installer
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: i2pbrowser-1.0.0-${{ github.sha }}.msi
|
name: i2pbrowser-1.0.0.msi
|
||||||
path: ./i2pbrowser-1.0.0.msi
|
path: ./i2pbrowser-1.0.0.msi
|
||||||
- name: build portable zip with Ant
|
- name: build portable zip with Ant
|
||||||
run: |
|
run: |
|
||||||
@ -189,7 +189,7 @@ jobs:
|
|||||||
- name: Upload Firefox Profile Portable Zip
|
- name: Upload Firefox Profile Portable Zip
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: i2pbrowser-portable-${{ github.sha }}.zip
|
name: i2pbrowser-portable.zip
|
||||||
path: ./i2pbrowser-portable.zip
|
path: ./i2pbrowser-portable.zip
|
||||||
|
|
||||||
buildmac:
|
buildmac:
|
||||||
@ -227,7 +227,7 @@ jobs:
|
|||||||
- name: Upload Firefox Profile DMG Installer
|
- name: Upload Firefox Profile DMG Installer
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: i2pbrowser-1.0.0-${{ github.sha }}.dmg
|
name: i2pbrowser-1.0.0.dmg
|
||||||
path: ./i2pbrowser-1.0.0.dmg
|
path: ./i2pbrowser-1.0.0.dmg
|
||||||
- name: build pkg with Ant
|
- name: build pkg with Ant
|
||||||
run: |
|
run: |
|
||||||
@ -236,5 +236,5 @@ jobs:
|
|||||||
- name: Upload Firefox Profile PKG Installer
|
- name: Upload Firefox Profile PKG Installer
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: i2pbrowser-1.0.0-${{ github.sha }}.pkg
|
name: i2pbrowser-1.0.0.pkg
|
||||||
path: ./i2pbrowser-1.0.0.pkg
|
path: ./i2pbrowser-1.0.0.pkg
|
289
.github/workflows/release.yml
vendored
289
.github/workflows/release.yml
vendored
@ -1,5 +1,7 @@
|
|||||||
name: Release
|
name: Release
|
||||||
|
|
||||||
|
#on: [push]
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
# Sequence of patterns matched against refs/tags
|
# Sequence of patterns matched against refs/tags
|
||||||
@ -9,237 +11,68 @@ on:
|
|||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
permissions:
|
||||||
steps:
|
contents: write
|
||||||
- name: dependencies
|
|
||||||
run: sudo apt install gettext golang-go git ant
|
|
||||||
- uses: actions/checkout@v4
|
|
||||||
- name: Set up JDK 21
|
|
||||||
uses: actions/setup-java@v4
|
|
||||||
with:
|
|
||||||
java-version: '21'
|
|
||||||
distribution: 'temurin'
|
|
||||||
- name : Generate override.properties
|
|
||||||
run: |
|
|
||||||
rm -f override.properties
|
|
||||||
echo "build.built-by=GitHub Actions" >> override.properties
|
|
||||||
echo "noExe=true" >> override.properties
|
|
||||||
- name: install crx3
|
|
||||||
run: go install github.com/mediabuyerbot/go-crx3/crx3@latest
|
|
||||||
- name: install dzip
|
|
||||||
run: go install github.com/delicb/dzip@latest
|
|
||||||
- name: install amo-version
|
|
||||||
run: go install github.com/eyedeekay/amo-version@a4f4119eac453a14d6b6184b656320eb72b5da3c
|
|
||||||
- name: install manifest-json-version
|
|
||||||
run: go install github.com/eyedeekay/manifest-json-version@latest
|
|
||||||
- run: git clone https://github.com/i2p/i2p.i2p ../i2p.i2p
|
|
||||||
- run: cd ../i2p.i2p && ant builddep
|
|
||||||
- name: build with Ant
|
|
||||||
run: |
|
|
||||||
export PATH=$PATH:$(go env GOPATH)/bin
|
|
||||||
ant distclean jpackage debian
|
|
||||||
- name: Upload Firefox Profile Strict
|
|
||||||
uses: actions/upload-artifact@v4
|
|
||||||
with:
|
|
||||||
name: i2p.firefox.base.profile-${{ github.sha }}.zip
|
|
||||||
path: ./src/i2p.firefox.base.profile.zip
|
|
||||||
- name: Upload Firefox Profile Usability
|
|
||||||
uses: actions/upload-artifact@v4
|
|
||||||
with:
|
|
||||||
name: i2p.firefox.usability.profile-${{ github.sha }}.zip
|
|
||||||
path: ./src/i2p.firefox.usability.profile.zip
|
|
||||||
- name: Upload Chromium Profile Strict
|
|
||||||
uses: actions/upload-artifact@v4
|
|
||||||
with:
|
|
||||||
name: i2p.chromium.base.profile-${{ github.sha }}.zip
|
|
||||||
path: ./src/i2p.chromium.base.profile.zip
|
|
||||||
- name: Upload Chromium Profile Usability
|
|
||||||
uses: actions/upload-artifact@v4
|
|
||||||
with:
|
|
||||||
name: i2p.chromium.usability.profile-${{ github.sha }}.zip
|
|
||||||
path: ./src/i2p.chromium.usability.profile.zip
|
|
||||||
- name: Upload i2pfirefox.jar
|
|
||||||
uses: actions/upload-artifact@v4
|
|
||||||
with:
|
|
||||||
name: i2pfirefox-${{ github.sha }}.jar
|
|
||||||
path: ./src/build/i2pfirefox.jar
|
|
||||||
- name: Upload i2pfirefox-plugin.jar
|
|
||||||
uses: actions/upload-artifact@v4
|
|
||||||
with:
|
|
||||||
name: i2pfirefox-plugin-${{ github.sha }}.jar
|
|
||||||
path: ./src/build/i2pfirefox-plugin.jar
|
|
||||||
- name: Upload i2pbrowser.tar.gz
|
|
||||||
uses: actions/upload-artifact@v4
|
|
||||||
with:
|
|
||||||
name: i2pbrowser-${{ github.sha }}.tar.gz
|
|
||||||
path: ./i2pbrowser.tar.gz
|
|
||||||
- name: Upload i2pbrowser.deb
|
|
||||||
uses: actions/upload-artifact@v4
|
|
||||||
with:
|
|
||||||
name: i2pbrowser_${{ github.sha }}_amd64.deb
|
|
||||||
path: ./i2pbrowser_1.0.0_amd64.deb
|
|
||||||
- name: build plugin with Ant
|
|
||||||
run: |
|
|
||||||
export PATH=$PATH:$(go env GOPATH)/bin
|
|
||||||
ant distclean pluginzip
|
|
||||||
- name: Upload i2pfirefox.zip (unsigned plugin)
|
|
||||||
uses: actions/upload-artifact@v4
|
|
||||||
with:
|
|
||||||
name: i2pfirefox-${{ github.sha }}.zip
|
|
||||||
path: ./plugin.zip
|
|
||||||
- name: Run release upload script
|
|
||||||
run: |
|
|
||||||
./preprelease.sh
|
|
||||||
./release.sh
|
|
||||||
|
|
||||||
|
|
||||||
buildrpm:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
container: fedora
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- name: dependencies
|
|
||||||
run: sudo yum install -y gettext golang-go git ant jq wget curl gpg xz ca-certificates rpm-build
|
|
||||||
- uses: actions/checkout@v4
|
|
||||||
- name: Set up JDK 21
|
|
||||||
uses: actions/setup-java@v4
|
|
||||||
with:
|
|
||||||
java-version: '21'
|
|
||||||
distribution: 'temurin'
|
|
||||||
- run: echo [Adoptium] >> /etc/yum.repos.d/adoptium.repo
|
|
||||||
- run: echo name=Adoptium >> /etc/yum.repos.d/adoptium.repo
|
|
||||||
- run: . /etc/os-release; echo baseurl=https://packages.adoptium.net/artifactory/rpm/fedora/$VERSION_ID/x86_64/ >> /etc/yum.repos.d/adoptium.repo
|
|
||||||
- run: echo enabled=1 >> /etc/yum.repos.d/adoptium.repo
|
|
||||||
- run: echo gpgcheck=1 >> /etc/yum.repos.d/adoptium.repo
|
|
||||||
- run: echo gpgkey=https://packages.adoptium.net/artifactory/api/gpg/key/public >> /etc/yum.repos.d/adoptium.repo
|
|
||||||
- run: dnf clean all && rm -r /var/cache/dnf && dnf upgrade -y && dnf update -y
|
|
||||||
- run: dnf install -y temurin-21-jdk
|
|
||||||
- name: Generate override.properties
|
|
||||||
run: |
|
|
||||||
rm -f override.properties
|
|
||||||
echo "build.built-by=GitHub Actions" >> override.properties
|
|
||||||
echo "noExe=true" >> override.properties
|
|
||||||
- name: install crx3
|
|
||||||
run: go install github.com/mediabuyerbot/go-crx3/crx3@latest
|
|
||||||
- name: install dzip
|
|
||||||
run: go install github.com/delicb/dzip@latest
|
|
||||||
- name: install amo-version
|
|
||||||
run: go install github.com/eyedeekay/amo-version@a4f4119eac453a14d6b6184b656320eb72b5da3c
|
|
||||||
- name: install manifest-json-version
|
|
||||||
run: go install github.com/eyedeekay/manifest-json-version@latest
|
|
||||||
- run: git clone https://github.com/i2p/i2p.i2p ../i2p.i2p
|
|
||||||
- run: cd ../i2p.i2p && ant builddep
|
|
||||||
- name: build with Ant
|
|
||||||
run: |
|
|
||||||
export PATH=$PATH:$(go env GOPATH)/bin
|
|
||||||
ant distclean jpackage fedora
|
|
||||||
find . -name '*.rpm'
|
|
||||||
- name: Upload i2pbrowser.rpm
|
|
||||||
uses: actions/upload-artifact@v4
|
|
||||||
with:
|
|
||||||
name: i2pbrowser-${{ github.sha }}.x86_64.rpm
|
|
||||||
path: ./i2pbrowser-1.0.0-1.x86_64.rpm
|
|
||||||
|
|
||||||
|
|
||||||
buildwin:
|
|
||||||
runs-on: windows-latest
|
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
- name: Set up JDK 21
|
|
||||||
uses: actions/setup-java@v4
|
|
||||||
with:
|
with:
|
||||||
java-version: '21'
|
sparse-checkout: |
|
||||||
distribution: 'temurin'
|
CHANGES.md
|
||||||
- uses: actions/setup-go@v5
|
sparse-checkout-cone-mode: false
|
||||||
with:
|
- name: sleep 15 minutes
|
||||||
go-version: '1.21'
|
|
||||||
- name : Generate override.properties
|
|
||||||
run: |
|
run: |
|
||||||
bash -c 'rm -f override.properties'
|
echo "sleeping 15 minutes to wait for artifacts"
|
||||||
bash -c 'echo "build.built-by=GitHub Actions" >> override.properties'
|
sleep 1m
|
||||||
bash -c 'echo "noExe=true" >> override.properties'
|
echo "sleeping 14 minutes to wait for artifacts"
|
||||||
- name: install crx3
|
sleep 1m
|
||||||
run: go install github.com/mediabuyerbot/go-crx3/crx3@latest
|
echo "sleeping 13 minutes to wait for artifacts"
|
||||||
- name: install dzip
|
sleep 1m
|
||||||
run: go install github.com/delicb/dzip@latest
|
echo "sleeping 12 minutes to wait for artifacts"
|
||||||
- name: install amo-version
|
sleep 1m
|
||||||
run: go install github.com/eyedeekay/amo-version@a4f4119eac453a14d6b6184b656320eb72b5da3c
|
echo "sleeping 11 minutes to wait for artifacts"
|
||||||
- name: install manifest-json-version
|
sleep 1m
|
||||||
run: go install github.com/eyedeekay/manifest-json-version@latest
|
echo "sleeping 10 minutes to wait for artifacts"
|
||||||
- run: git clone https://github.com/i2p/i2p.i2p ../i2p.i2p
|
sleep 1m
|
||||||
- run: cd ../i2p.i2p && ant builddep
|
echo "sleeping 9 minutes to wait for artifacts"
|
||||||
- name: build exe with Ant
|
sleep 1m
|
||||||
run: |
|
echo "sleeping 8 minutes to wait for artifacts"
|
||||||
ant windows
|
sleep 1m
|
||||||
bash -c 'ls *.exe'
|
echo "sleeping 7 minutes to wait for artifacts"
|
||||||
- name: Upload Firefox Profile EXE Installer
|
sleep 1m
|
||||||
uses: actions/upload-artifact@v4
|
echo "sleeping 6 minutes to wait for artifacts"
|
||||||
|
sleep 1m
|
||||||
|
echo "sleeping 5 minutes to wait for artifacts"
|
||||||
|
sleep 1m
|
||||||
|
echo "sleeping 4 minutes to wait for artifacts"
|
||||||
|
sleep 1m
|
||||||
|
echo "sleeping 3 minutes to wait for artifacts"
|
||||||
|
sleep 1m
|
||||||
|
echo "sleeping 2 minutes to wait for artifacts"
|
||||||
|
sleep 1m
|
||||||
|
echo "sleeping 1 minutes to wait for artifacts"
|
||||||
|
sleep 1m
|
||||||
|
- name: Download artifacts
|
||||||
|
id: download-artifact
|
||||||
|
uses: dawidd6/action-download-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: i2pbrowser-1.0.0-${{ github.sha }}.exe
|
skip_unpack: true
|
||||||
path: ./i2pbrowser-1.0.0.exe
|
workflow: ant.yml
|
||||||
- name: build msi with Ant
|
if_no_artifact_found: fail
|
||||||
run: |
|
# remove .zip file extension
|
||||||
ant windows-msi
|
- run: for f in *.zip; do unzip "$f"; rm "$f"; done
|
||||||
bash -c 'ls *.msi'
|
- run: echo "" | tee -a CHANGES.md
|
||||||
- name: Upload Firefox Profile MSI Installer
|
- run: echo "## Checksums" | tee -a CHANGES.md
|
||||||
uses: actions/upload-artifact@v4
|
- run: echo "" | tee -a CHANGES.md
|
||||||
|
- run: echo '```' | tee -a CHANGES.md
|
||||||
|
- run: sha256sum * | tee -a CHANGES.md
|
||||||
|
- run: echo '```' | tee -a CHANGES.md
|
||||||
|
- run: echo "" | tee -a CHANGES.md
|
||||||
|
- run: echo '```' | tee -a CHANGES.md
|
||||||
|
- run: file * | tee -a CHANGES.md
|
||||||
|
- run: echo '```' | tee -a CHANGES.md
|
||||||
|
- run: echo "" | tee -a CHANGES.md
|
||||||
|
- name: Upload artifacts
|
||||||
|
uses: ncipollo/release-action@v1
|
||||||
with:
|
with:
|
||||||
name: i2pbrowser-1.0.0-${{ github.sha }}.msi
|
artifacts: "*"
|
||||||
path: ./i2pbrowser-1.0.0.msi
|
bodyFile: "CHANGES.md"
|
||||||
- name: build portable zip with Ant
|
|
||||||
run: |
|
|
||||||
ant windows-portable
|
|
||||||
bash -c 'ls *.zip'
|
|
||||||
- name: Upload Firefox Profile Portable Zip
|
|
||||||
uses: actions/upload-artifact@v4
|
|
||||||
with:
|
|
||||||
name: i2pbrowser-portable-${{ github.sha }}.zip
|
|
||||||
path: ./i2pbrowser-portable.zip
|
|
||||||
|
|
||||||
buildmac:
|
|
||||||
runs-on: macos-latest
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v4
|
|
||||||
- name: Set up JDK 21
|
|
||||||
uses: actions/setup-java@v4
|
|
||||||
with:
|
|
||||||
java-version: '21'
|
|
||||||
distribution: 'temurin'
|
|
||||||
- uses: actions/setup-go@v5
|
|
||||||
with:
|
|
||||||
go-version: '1.21'
|
|
||||||
- name : Generate override.properties
|
|
||||||
run: |
|
|
||||||
bash -c 'rm -f override.properties'
|
|
||||||
bash -c 'echo "build.built-by=GitHub Actions" >> override.properties'
|
|
||||||
bash -c 'echo "noExe=true" >> override.properties'
|
|
||||||
- name: install crx3
|
|
||||||
run: go install github.com/mediabuyerbot/go-crx3/crx3@latest
|
|
||||||
- name: install dzip
|
|
||||||
run: go install github.com/delicb/dzip@latest
|
|
||||||
- name: install amo-version
|
|
||||||
run: go install github.com/eyedeekay/amo-version@a4f4119eac453a14d6b6184b656320eb72b5da3c
|
|
||||||
- name: install manifest-json-version
|
|
||||||
run: go install github.com/eyedeekay/manifest-json-version@latest
|
|
||||||
- run: git clone https://github.com/i2p/i2p.i2p ../i2p.i2p
|
|
||||||
- run: cd ../i2p.i2p && ant builddep
|
|
||||||
- name: build dmg with Ant
|
|
||||||
run: |
|
|
||||||
ant macos
|
|
||||||
bash -c 'ls *.dmg'
|
|
||||||
- name: Upload Firefox Profile DMG Installer
|
|
||||||
uses: actions/upload-artifact@v4
|
|
||||||
with:
|
|
||||||
name: i2pbrowser-1.0.0-${{ github.sha }}.dmg
|
|
||||||
path: ./i2pbrowser-1.0.0.dmg
|
|
||||||
- name: build pkg with Ant
|
|
||||||
run: |
|
|
||||||
ant macos-pkg
|
|
||||||
bash -c 'ls *.pkg'
|
|
||||||
- name: Upload Firefox Profile PKG Installer
|
|
||||||
uses: actions/upload-artifact@v4
|
|
||||||
with:
|
|
||||||
name: i2pbrowser-1.0.0-${{ github.sha }}.pkg
|
|
||||||
path: ./i2pbrowser-1.0.0.pkg
|
|
||||||
|
@ -55,6 +55,11 @@
|
|||||||
docs/BUILD
|
docs/BUILD
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
<li>
|
||||||
|
<a href="docs/I2P-PLUGIN.html">
|
||||||
|
docs/I2P-PLUGIN
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="docs/I2PBrowser.html">
|
<a href="docs/I2PBrowser.html">
|
||||||
docs/I2PBrowser
|
docs/I2PBrowser
|
||||||
|
49
CHANGES.md
49
CHANGES.md
@ -1,3 +1,10 @@
|
|||||||
|
Mon, July 8
|
||||||
|
-----------
|
||||||
|
|
||||||
|
- Fix a bug which caused the profile manager to fail to detect Firefox on some systems
|
||||||
|
- Fix a bug which caused the profile manager to use an unwritable directory on some systems
|
||||||
|
- Fix a bug where if user tried to run it from the home directory, the application would make sure that no firefoxes existed in any subdirectory before running
|
||||||
|
|
||||||
Thu, March 7
|
Thu, March 7
|
||||||
------------
|
------------
|
||||||
|
|
||||||
@ -169,4 +176,44 @@ Saturday, August 6
|
|||||||
|
|
||||||
- Implemented firefox detection
|
- Implemented firefox detection
|
||||||
- Implemented directory setup
|
- Implemented directory setup
|
||||||
- Implemented processBuilder generator
|
- Implemented processBuilder generator
|
||||||
|
## Checksums
|
||||||
|
|
||||||
|
```
|
||||||
|
dc8797cfae23640e27ed7b32a3e6ccec232d24411d64cd9e5b107f8c5384a70a CHANGES.md
|
||||||
|
9a36e15def2a95077027cd0db5f95b345a87a8edfe5e89ea7f83aaa3c94f5ebb i2p.chromium.base.profile.zip
|
||||||
|
97ae21d621f813fd2d91f5921fe1eee95ec0d01782bf93db7b3689f959a9f3b8 i2p.chromium.usability.profile.zip
|
||||||
|
5cd673bb27827e67796b52f26194b7b1504dddf1630ad9d9084ab6a318c6d20a i2p.firefox.base.profile.zip
|
||||||
|
556fc2df825e64b1463e88ec77a5de46bce61516a475e1136110363d5badabd2 i2p.firefox.usability.profile.zip
|
||||||
|
6d3882ac113116b8f40ce07985e779859a68f43f14278b40f1628ea5362acca5 i2pbrowser-1.0.0-1.x86_64.rpm
|
||||||
|
aa7185799b17fd7893818fe7728f3e3cb6b4c8022e033fc0f33f6be81e7b2c2f i2pbrowser-1.0.0.dmg
|
||||||
|
c307fb6556821258520a3d522cf7fbe2031aa421161fcac3e409f5ce20a1637a i2pbrowser-1.0.0.exe
|
||||||
|
5eae853ff7f8b9a05c4c7111147882a54aabd1cf581d21396878055a54a3efc7 i2pbrowser-1.0.0.msi
|
||||||
|
cda1bb2058048a4303bbc65543a0f340ade1c88881ee60704333e767bae10db6 i2pbrowser-1.0.0.pkg
|
||||||
|
183197aa39e891d5763ef5449957b9d9790bdfaaa06760288526f6283b865d97 i2pbrowser-portable.zip
|
||||||
|
f017951df66f2e3d2d57886085a95bd2463cc8f7d793683960da30b842b9b17b i2pbrowser.tar.gz
|
||||||
|
4538172d9753967485566e52f064dbc06a5123971044d973766de28051d53eb1 i2pbrowser_1.0.0_amd64.deb
|
||||||
|
6b5dd3e4ab1bcb3df4a5a758b5469239453c713bb6266bc5eea8b0d9ec7aa413 i2pfirefox-plugin.jar
|
||||||
|
85ce64a3c03c72421947c777a72d42be6fc568c5317070927463accb347b703f i2pfirefox.jar
|
||||||
|
9856613f8229a773ef54a9e7e2a37a6c788755d96393478afce8db7439404e42 plugin.zip
|
||||||
|
```
|
||||||
|
|
||||||
|
```
|
||||||
|
CHANGES.md: ASCII text
|
||||||
|
i2p.chromium.base.profile.zip: Zip archive data, at least v2.0 to extract, compression method=store
|
||||||
|
i2p.chromium.usability.profile.zip: Zip archive data, at least v2.0 to extract, compression method=store
|
||||||
|
i2p.firefox.base.profile.zip: Zip archive data, at least v2.0 to extract, compression method=store
|
||||||
|
i2p.firefox.usability.profile.zip: Zip archive data, at least v2.0 to extract, compression method=store
|
||||||
|
i2pbrowser-1.0.0-1.x86_64.rpm: RPM v3.0 bin i386/x86_64
|
||||||
|
i2pbrowser-1.0.0.dmg: zlib compressed data
|
||||||
|
i2pbrowser-1.0.0.exe: PE32+ executable (GUI) x86-64, for MS Windows
|
||||||
|
i2pbrowser-1.0.0.msi: Composite Document File V2 Document, Little Endian, Os: Windows, Version 6.2, MSI Installer, Code page: 1252, Title: Installation Database, Subject: i2pbrowser, Author: Unknown, Keywords: Installer, Comments: This installer database contains the logic and data required to install i2pbrowser., Template: x64;1033, Revision Number: {6D1D56D8-CB72-4709-BD0B-0FDBF71C6D32}, Create Time/Date: Sun Mar 10 06:04:32 2024, Last Saved Time/Date: Sun Mar 10 06:04:32 2024, Number of Pages: 200, Number of Words: 10, Name of Creating Application: Windows Installer XML Toolset (3.14.0.8606), Security: 2
|
||||||
|
i2pbrowser-1.0.0.pkg: xar archive compressed TOC: 1244, SHA-1 checksum, contains zlib compressed data
|
||||||
|
i2pbrowser-portable.zip: Zip archive data, at least v2.0 to extract, compression method=deflate
|
||||||
|
i2pbrowser.tar.gz: gzip compressed data, from Unix, original size modulo 2^32 725985280
|
||||||
|
i2pbrowser_1.0.0_amd64.deb: Debian binary package (format 2.0), with control.tar.zs, data compression zst
|
||||||
|
i2pfirefox-plugin.jar: Java archive data (JAR)
|
||||||
|
i2pfirefox.jar: Java archive data (JAR)
|
||||||
|
plugin.zip: Zip archive data, at least v1.0 to extract, compression method=store
|
||||||
|
```
|
||||||
|
|
||||||
|
@ -55,6 +55,11 @@
|
|||||||
docs/BUILD
|
docs/BUILD
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
<li>
|
||||||
|
<a href="docs/I2P-PLUGIN.html">
|
||||||
|
docs/I2P-PLUGIN
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="docs/I2PBrowser.html">
|
<a href="docs/I2PBrowser.html">
|
||||||
docs/I2PBrowser
|
docs/I2PBrowser
|
||||||
|
23
README.md
23
README.md
@ -11,6 +11,28 @@ trackers, and jerks using off-the-shelf techniques and exploits. It is fundament
|
|||||||
to make changes which un-trust your browser vendor, your OS, your package manager or any
|
to make changes which un-trust your browser vendor, your OS, your package manager or any
|
||||||
other system that exists underneath it. **It is just a profile manager.**
|
other system that exists underneath it. **It is just a profile manager.**
|
||||||
|
|
||||||
|
**What is this?**
|
||||||
|
|
||||||
|
This is a browser profile manager which pre-configures a browser on the host system, usually
|
||||||
|
Firefox or Tor Browser, for browsing I2P. When acting as an I2P Plugin, it adds GUI elements to
|
||||||
|
I2P for launching the browser in a highly restricted "Safe" mode(the default) or a more permissive
|
||||||
|
"Usability" mode.
|
||||||
|
|
||||||
|
This package expresses functionality that has existed in many places at many times, sometimes
|
||||||
|
bundled with other software. As it has developed here, the border of where the Easy-Install
|
||||||
|
ends and Firefox Profile Manager begins has become clearer. This repository contains the profile
|
||||||
|
manager and it's buildsystem, the whole profile manager, and nothing but the profile manager.
|
||||||
|
It can be used independently of other software, provided an I2P proxy on the host system somewhere.
|
||||||
|
|
||||||
|
However, in practice, most people probably get it alongside an I2P router, through the **I2P Easy-Install Bundle for Windows**.
|
||||||
|
|
||||||
|
**What version numbers should I pay attention to?**
|
||||||
|
When I decided to port the `.bat` launcher scripts from the Easy-Install bundle to Java, this project
|
||||||
|
was created and started using it's own version numbers. This was the practice up until version 1.5.0,
|
||||||
|
which was the last version to use a different version number than I2P itself. Starting in April 2024,
|
||||||
|
`i2p.plugins.firefox` will follow along with the Java I2P major and minor version numbers. Incremental
|
||||||
|
changes may become differing point releases.
|
||||||
|
|
||||||
**All packages require a running I2P router.**
|
**All packages require a running I2P router.**
|
||||||
|
|
||||||
**[Windows users should see the Easy-Install Bundle](https://i2pgit.org/i2p-hackers/i2p.firefox)**
|
**[Windows users should see the Easy-Install Bundle](https://i2pgit.org/i2p-hackers/i2p.firefox)**
|
||||||
@ -47,6 +69,7 @@ directory for Firefox, and the `src/i2p.chromium.*.profile/extensions/*.js/*` di
|
|||||||
|
|
||||||
For platform specific instructions, see
|
For platform specific instructions, see
|
||||||
|
|
||||||
|
- [I2P-PLUGIN.md](docs/I2P-PLUGIN.md)/[I2P-PLUGIN.html](docs/I2P-PLUGIN.html)
|
||||||
- [LINUX.md](docs/LINUX.md)/[LINUX.html](docs/LINUX.html)
|
- [LINUX.md](docs/LINUX.md)/[LINUX.html](docs/LINUX.html)
|
||||||
- [OSX.md](docs/OSX.md)/[OSX.html](docs/OSX.html)
|
- [OSX.md](docs/OSX.md)/[OSX.html](docs/OSX.html)
|
||||||
- [WINDOWS.md](docs/WINDOWS.md)/[WINDOWS.html](docs/WINDOWS.html)
|
- [WINDOWS.md](docs/WINDOWS.md)/[WINDOWS.html](docs/WINDOWS.html)
|
||||||
|
@ -55,6 +55,11 @@
|
|||||||
docs/BUILD
|
docs/BUILD
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
<li>
|
||||||
|
<a href="docs/I2P-PLUGIN.html">
|
||||||
|
docs/I2P-PLUGIN
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="docs/I2PBrowser.html">
|
<a href="docs/I2PBrowser.html">
|
||||||
docs/I2PBrowser
|
docs/I2PBrowser
|
||||||
@ -181,7 +186,7 @@ NoScript
|
|||||||
11.4.18
|
11.4.18
|
||||||
https://clients2.google.com/service/update2/crx
|
https://clients2.google.com/service/update2/crx
|
||||||
LocalCDN
|
LocalCDN
|
||||||
2.6.64
|
2.6.65
|
||||||
https://clients2.google.com/service/update2/crx
|
https://clients2.google.com/service/update2/crx
|
||||||
uBlock Origin
|
uBlock Origin
|
||||||
1.56.0
|
1.56.0
|
||||||
|
20
VERSION.md
20
VERSION.md
@ -12,17 +12,17 @@ noscript
|
|||||||
11.4.29
|
11.4.29
|
||||||
https://addons.mozilla.org/firefox/downloads/file/4206186/noscript-11.4.29.xpi
|
https://addons.mozilla.org/firefox/downloads/file/4206186/noscript-11.4.29.xpi
|
||||||
localcdn-fork-of-decentraleyes
|
localcdn-fork-of-decentraleyes
|
||||||
2.6.64
|
2.6.69
|
||||||
https://addons.mozilla.org/firefox/downloads/file/4243456/localcdn_fork_of_decentraleyes-2.6.64.xpi
|
https://addons.mozilla.org/firefox/downloads/file/4303757/localcdn_fork_of_decentraleyes-2.6.69.xpi
|
||||||
onion-in-container-browsing
|
onion-in-container-browsing
|
||||||
0.82
|
0.82
|
||||||
https://addons.mozilla.org/firefox/downloads/file/3904685/onion_in_container_browsing-0.82.xpi
|
https://addons.mozilla.org/firefox/downloads/file/3904685/onion_in_container_browsing-0.82.xpi
|
||||||
javascript-restrictor
|
javascript-restrictor
|
||||||
0.17
|
0.18.1
|
||||||
https://addons.mozilla.org/firefox/downloads/file/4190089/javascript_restrictor-0.17.xpi
|
https://addons.mozilla.org/firefox/downloads/file/4310951/javascript_restrictor-0.18.1.xpi
|
||||||
ublock-origin
|
ublock-origin
|
||||||
1.56.0
|
1.58.0
|
||||||
https://addons.mozilla.org/firefox/downloads/file/4237670/ublock_origin-1.56.0.xpi
|
https://addons.mozilla.org/firefox/downloads/file/4290466/ublock_origin-1.58.0.xpi
|
||||||
```
|
```
|
||||||
|
|
||||||
## Chromium
|
## Chromium
|
||||||
@ -32,15 +32,15 @@ __MSG_extensionName__
|
|||||||
1.29
|
1.29
|
||||||
https://clients2.google.com/service/update2/crx
|
https://clients2.google.com/service/update2/crx
|
||||||
NoScript
|
NoScript
|
||||||
11.4.18
|
11.4.30
|
||||||
https://clients2.google.com/service/update2/crx
|
https://clients2.google.com/service/update2/crx
|
||||||
LocalCDN
|
LocalCDN
|
||||||
2.6.64
|
2.6.67
|
||||||
https://clients2.google.com/service/update2/crx
|
https://clients2.google.com/service/update2/crx
|
||||||
uBlock Origin
|
uBlock Origin
|
||||||
1.56.0
|
1.58.0
|
||||||
https://clients2.google.com/service/update2/crx
|
https://clients2.google.com/service/update2/crx
|
||||||
__MSG_extensionName__
|
__MSG_extensionName__
|
||||||
0.17
|
0.18.1
|
||||||
https://clients2.google.com/service/update2/crx
|
https://clients2.google.com/service/update2/crx
|
||||||
```
|
```
|
||||||
|
@ -328,7 +328,7 @@ Linux(because the top command will be run and the script will exit).\n\nBoth det
|
|||||||
|
|
||||||
<target name="buildNum">
|
<target name="buildNum">
|
||||||
<buildnumber file="scripts/build.number" />
|
<buildnumber file="scripts/build.number" />
|
||||||
<property name="release.number" value="1.3.0" />
|
<property name="release.number" value="1.4.991" />
|
||||||
<exec executable="echo" osfamily="unix">
|
<exec executable="echo" osfamily="unix">
|
||||||
<arg value="${release.number}-${build.number}" />
|
<arg value="${release.number}-${build.number}" />
|
||||||
</exec>
|
</exec>
|
||||||
|
@ -3,4 +3,4 @@ export GITHUB_USER=eyedeekay
|
|||||||
export GITHUB_REPO=i2p.plugins.firefox
|
export GITHUB_REPO=i2p.plugins.firefox
|
||||||
export GITHUB_NAME="Updates extensions, plugin support temporarily removed(Stay on the old version)"
|
export GITHUB_NAME="Updates extensions, plugin support temporarily removed(Stay on the old version)"
|
||||||
export GITHUB_DESCRIPTION=$(cat CHANGES.md VERSION.md)
|
export GITHUB_DESCRIPTION=$(cat CHANGES.md VERSION.md)
|
||||||
export GITHUB_TAG=1.3.1
|
export GITHUB_TAG=$(git describe --tags --abbrev=0)
|
@ -55,6 +55,11 @@
|
|||||||
BUILD
|
BUILD
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
<li>
|
||||||
|
<a href="I2P-PLUGIN.html">
|
||||||
|
I2P-PLUGIN
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="I2PBrowser.html">
|
<a href="I2PBrowser.html">
|
||||||
I2PBrowser
|
I2PBrowser
|
||||||
@ -152,6 +157,42 @@
|
|||||||
<h2>
|
<h2>
|
||||||
Build Dependencies
|
Build Dependencies
|
||||||
</h2>
|
</h2>
|
||||||
|
<p>
|
||||||
|
<strong>
|
||||||
|
SHORTCUT:
|
||||||
|
</strong>
|
||||||
|
All the build artifacts can be produced by the description in the
|
||||||
|
<code>
|
||||||
|
.yaml
|
||||||
|
</code>
|
||||||
|
files in
|
||||||
|
<code>
|
||||||
|
.github/workflows
|
||||||
|
</code>
|
||||||
|
.
|
||||||
|
These can be run on Github’s infrastructure, or on a local PC using
|
||||||
|
<a href="https://github.com/nektos/act">
|
||||||
|
https://github.com/nektos/act
|
||||||
|
</a>
|
||||||
|
.
|
||||||
|
Windows targets will require a Windows PC!
|
||||||
|
Doing things this way deals with all the dependency issues that Windows doesn’t really give you a good way to deal with automatically.
|
||||||
|
It also guarantees that the same base container and environment gets used for every build no matter what machine it runs on.
|
||||||
|
I highly recommend you use either Github CI or
|
||||||
|
<code>
|
||||||
|
nektos/act
|
||||||
|
</code>
|
||||||
|
for dev builds of this software, as it
|
||||||
|
<strong>
|
||||||
|
automates literally every one of the steps
|
||||||
|
</strong>
|
||||||
|
.
|
||||||
|
CI-based builds follow the
|
||||||
|
<code>
|
||||||
|
WSL
|
||||||
|
</code>
|
||||||
|
version of the instructions.
|
||||||
|
</p>
|
||||||
<p>
|
<p>
|
||||||
You will need
|
You will need
|
||||||
<code>
|
<code>
|
||||||
|
@ -2,6 +2,14 @@
|
|||||||
|
|
||||||
## Build Dependencies
|
## Build Dependencies
|
||||||
|
|
||||||
|
**SHORTCUT:** All the build artifacts can be produced by the description in the `.yaml` files in `.github/workflows`.
|
||||||
|
These can be run on Github's infrastructure, or on a local PC using https://github.com/nektos/act.
|
||||||
|
Windows targets will require a Windows PC!
|
||||||
|
Doing things this way deals with all the dependency issues that Windows doesn't really give you a good way to deal with automatically.
|
||||||
|
It also guarantees that the same base container and environment gets used for every build no matter what machine it runs on.
|
||||||
|
I highly recommend you use either Github CI or `nektos/act` for dev builds of this software, as it **automates literally every one of the steps**.
|
||||||
|
CI-based builds follow the `WSL` version of the instructions.
|
||||||
|
|
||||||
You will need `ant` and java `java` and for building the jar. You will need
|
You will need `ant` and java `java` and for building the jar. You will need
|
||||||
`jpackage` for many of the potential build targets. I've been using Java 18
|
`jpackage` for many of the potential build targets. I've been using Java 18
|
||||||
on Debian mostly, on Debian and Ubuntu, install the dependencies with:
|
on Debian mostly, on Debian and Ubuntu, install the dependencies with:
|
||||||
|
1106
docs/I2P-PLUGIN.html
Normal file
1106
docs/I2P-PLUGIN.html
Normal file
File diff suppressed because it is too large
Load Diff
23
docs/I2P-PLUGIN.md
Normal file
23
docs/I2P-PLUGIN.md
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
### I2P Plugin Support
|
||||||
|
|
||||||
|
Since version `1.5.0`, this package has had basic plugin support in Java I2P.
|
||||||
|
This means it can be integrated with your I2P installation or portable package, with
|
||||||
|
the benefit of reduced size requirements, automatic updates, and integration with the I2P UI.
|
||||||
|
Installation in this way is **platform-independent**, the same package is used for Linux, Windows, and OSX.
|
||||||
|
In this type of installation, the profile manager install is entirely managed by I2P.
|
||||||
|
Uninstalling I2P will also uninstall the profile manager.
|
||||||
|
|
||||||
|
#### Downloading the Plugin
|
||||||
|
|
||||||
|
Right now, the best way to download the plugin is from the Github releases page.
|
||||||
|
First, download the `i2pfirefox.su3` file from [the latest release](https://github.com/eyedeekay/i2p.plugins.firefox/releases).
|
||||||
|
Versions ending in `0` will always have a plugin release, starting with `1.5.0`.
|
||||||
|
Dev builds will not have a reliable plugin release.
|
||||||
|
|
||||||
|
#### Install the plugin "From File"
|
||||||
|
|
||||||
|
Once you have downloaded the `i2pfirefox.su3` file, open [`http://127.0.0.1:7657/configplugins`](http://127.0.0.1:7657/configplugins) and scroll to the bottom of the page.
|
||||||
|
Under the heading **Installation from File**, click the "Browse" button.
|
||||||
|
In the window that appears, select the `i2pfirefox.su3` file you just downloaded.
|
||||||
|
Finally, click the "Install plugin from File" button.
|
||||||
|
The plugin will install and start shortly.
|
@ -55,6 +55,11 @@
|
|||||||
BUILD
|
BUILD
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
<li>
|
||||||
|
<a href="I2P-PLUGIN.html">
|
||||||
|
I2P-PLUGIN
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="I2PBrowser.html">
|
<a href="I2PBrowser.html">
|
||||||
I2PBrowser
|
I2PBrowser
|
||||||
|
@ -55,6 +55,11 @@
|
|||||||
BUILD
|
BUILD
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
<li>
|
||||||
|
<a href="I2P-PLUGIN.html">
|
||||||
|
I2P-PLUGIN
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="I2PBrowser.html">
|
<a href="I2PBrowser.html">
|
||||||
I2PBrowser
|
I2PBrowser
|
||||||
|
@ -55,6 +55,11 @@
|
|||||||
BUILD
|
BUILD
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
<li>
|
||||||
|
<a href="I2P-PLUGIN.html">
|
||||||
|
I2P-PLUGIN
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="I2PBrowser.html">
|
<a href="I2PBrowser.html">
|
||||||
I2PBrowser
|
I2PBrowser
|
||||||
|
@ -55,6 +55,11 @@
|
|||||||
BUILD
|
BUILD
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
<li>
|
||||||
|
<a href="I2P-PLUGIN.html">
|
||||||
|
I2P-PLUGIN
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="I2PBrowser.html">
|
<a href="I2PBrowser.html">
|
||||||
I2PBrowser
|
I2PBrowser
|
||||||
|
@ -55,6 +55,11 @@
|
|||||||
BUILD
|
BUILD
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
<li>
|
||||||
|
<a href="I2P-PLUGIN.html">
|
||||||
|
I2P-PLUGIN
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="I2PBrowser.html">
|
<a href="I2PBrowser.html">
|
||||||
I2PBrowser
|
I2PBrowser
|
||||||
|
@ -55,6 +55,11 @@
|
|||||||
BUILD
|
BUILD
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
<li>
|
||||||
|
<a href="I2P-PLUGIN.html">
|
||||||
|
I2P-PLUGIN
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="I2PBrowser.html">
|
<a href="I2PBrowser.html">
|
||||||
I2PBrowser
|
I2PBrowser
|
||||||
|
@ -55,6 +55,11 @@
|
|||||||
BUILD
|
BUILD
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
<li>
|
||||||
|
<a href="I2P-PLUGIN.html">
|
||||||
|
I2P-PLUGIN
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="I2PBrowser.html">
|
<a href="I2PBrowser.html">
|
||||||
I2PBrowser
|
I2PBrowser
|
||||||
|
@ -55,6 +55,11 @@
|
|||||||
BUILD
|
BUILD
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
<li>
|
||||||
|
<a href="I2P-PLUGIN.html">
|
||||||
|
I2P-PLUGIN
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="I2PBrowser.html">
|
<a href="I2PBrowser.html">
|
||||||
I2PBrowser
|
I2PBrowser
|
||||||
|
@ -55,6 +55,11 @@
|
|||||||
BUILD
|
BUILD
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
<li>
|
||||||
|
<a href="I2P-PLUGIN.html">
|
||||||
|
I2P-PLUGIN
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="I2PBrowser.html">
|
<a href="I2PBrowser.html">
|
||||||
I2PBrowser
|
I2PBrowser
|
||||||
|
@ -55,6 +55,11 @@
|
|||||||
BUILD
|
BUILD
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
<li>
|
||||||
|
<a href="I2P-PLUGIN.html">
|
||||||
|
I2P-PLUGIN
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="I2PBrowser.html">
|
<a href="I2PBrowser.html">
|
||||||
I2PBrowser
|
I2PBrowser
|
||||||
|
@ -55,6 +55,11 @@
|
|||||||
BUILD
|
BUILD
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
<li>
|
||||||
|
<a href="I2P-PLUGIN.html">
|
||||||
|
I2P-PLUGIN
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="I2PBrowser.html">
|
<a href="I2PBrowser.html">
|
||||||
I2PBrowser
|
I2PBrowser
|
||||||
|
@ -55,6 +55,11 @@
|
|||||||
BUILD
|
BUILD
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
<li>
|
||||||
|
<a href="I2P-PLUGIN.html">
|
||||||
|
I2P-PLUGIN
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="I2PBrowser.html">
|
<a href="I2PBrowser.html">
|
||||||
I2PBrowser
|
I2PBrowser
|
||||||
|
@ -55,6 +55,11 @@
|
|||||||
BUILD
|
BUILD
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
<li>
|
||||||
|
<a href="I2P-PLUGIN.html">
|
||||||
|
I2P-PLUGIN
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="I2PBrowser.html">
|
<a href="I2PBrowser.html">
|
||||||
I2PBrowser
|
I2PBrowser
|
||||||
|
@ -55,6 +55,11 @@
|
|||||||
BUILD
|
BUILD
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
<li>
|
||||||
|
<a href="I2P-PLUGIN.html">
|
||||||
|
I2P-PLUGIN
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="I2PBrowser.html">
|
<a href="I2PBrowser.html">
|
||||||
I2PBrowser
|
I2PBrowser
|
||||||
@ -163,7 +168,7 @@
|
|||||||
</h4>
|
</h4>
|
||||||
<p>
|
<p>
|
||||||
<strong>
|
<strong>
|
||||||
(Not Recommended! This functionality is already included in the Easy-Install Bundle for Windows)
|
(Recommended for advanced users ONLY. Most people should be using Easy-Install Bundle for Windows)
|
||||||
</strong>
|
</strong>
|
||||||
</p>
|
</p>
|
||||||
<ol>
|
<ol>
|
||||||
|
@ -7,7 +7,7 @@ an unbundled I2P router with an external JVM.
|
|||||||
|
|
||||||
#### Windows Jpackage: `.zip`
|
#### Windows Jpackage: `.zip`
|
||||||
|
|
||||||
**(Not Recommended! This functionality is already included in the Easy-Install Bundle for Windows)**
|
**(Recommended for advanced users ONLY. Most people should be using Easy-Install Bundle for Windows)**
|
||||||
|
|
||||||
1. Start your I2P Router
|
1. Start your I2P Router
|
||||||
2. Download the latest release `.zip` from [Github](https://github.com/eyedeekay/i2p.plugins.firefox/releases) and verify it's hash.
|
2. Download the latest release `.zip` from [Github](https://github.com/eyedeekay/i2p.plugins.firefox/releases) and verify it's hash.
|
||||||
|
56
index.html
56
index.html
@ -55,6 +55,11 @@
|
|||||||
docs/BUILD
|
docs/BUILD
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
<li>
|
||||||
|
<a href="docs/I2P-PLUGIN.html">
|
||||||
|
docs/I2P-PLUGIN
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="docs/I2PBrowser.html">
|
<a href="docs/I2PBrowser.html">
|
||||||
docs/I2PBrowser
|
docs/I2PBrowser
|
||||||
@ -172,6 +177,48 @@
|
|||||||
It is just a profile manager.
|
It is just a profile manager.
|
||||||
</strong>
|
</strong>
|
||||||
</p>
|
</p>
|
||||||
|
<p>
|
||||||
|
<strong>
|
||||||
|
What is this?
|
||||||
|
</strong>
|
||||||
|
</p>
|
||||||
|
<p>
|
||||||
|
This is a browser profile manager which pre-configures a browser on the host system, usually
|
||||||
|
Firefox or Tor Browser, for browsing I2P. When acting as an I2P Plugin, it adds GUI elements to
|
||||||
|
I2P for launching the browser in a highly restricted “Safe” mode(the default) or a more permissive
|
||||||
|
“Usability” mode.
|
||||||
|
</p>
|
||||||
|
<p>
|
||||||
|
This package expresses functionality that has existed in many places at many times, sometimes
|
||||||
|
bundled with other software. As it has developed here, the border of where the Easy-Install
|
||||||
|
ends and Firefox Profile Manager begins has become clearer. This repository contains the profile
|
||||||
|
manager and it’s buildsystem, the whole profile manager, and nothing but the profile manager.
|
||||||
|
It can be used independently of other software, provided an I2P proxy on the host system somewhere.
|
||||||
|
</p>
|
||||||
|
<p>
|
||||||
|
However, in practice, most people probably get it alongside an I2P router, through the
|
||||||
|
<strong>
|
||||||
|
I2P Easy-Install Bundle for Windows
|
||||||
|
</strong>
|
||||||
|
.
|
||||||
|
</p>
|
||||||
|
<p>
|
||||||
|
<strong>
|
||||||
|
What version numbers should I pay attention to?
|
||||||
|
</strong>
|
||||||
|
When I decided to port the
|
||||||
|
<code>
|
||||||
|
.bat
|
||||||
|
</code>
|
||||||
|
launcher scripts from the Easy-Install bundle to Java, this project
|
||||||
|
was created and started using it’s own version numbers. This was the practice up until version 1.5.0,
|
||||||
|
which was the last version to use a different version number than I2P itself. Starting in April 2024,
|
||||||
|
<code>
|
||||||
|
i2p.plugins.firefox
|
||||||
|
</code>
|
||||||
|
will follow along with the Java I2P major and minor version numbers. Incremental
|
||||||
|
changes may become differing point releases.
|
||||||
|
</p>
|
||||||
<p>
|
<p>
|
||||||
<strong>
|
<strong>
|
||||||
All packages require a running I2P router.
|
All packages require a running I2P router.
|
||||||
@ -269,6 +316,15 @@
|
|||||||
For platform specific instructions, see
|
For platform specific instructions, see
|
||||||
</p>
|
</p>
|
||||||
<ul>
|
<ul>
|
||||||
|
<li>
|
||||||
|
<a href="docs/I2P-PLUGIN.md">
|
||||||
|
I2P-PLUGIN.md
|
||||||
|
</a>
|
||||||
|
/
|
||||||
|
<a href="docs/I2P-PLUGIN.html">
|
||||||
|
I2P-PLUGIN.html
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="docs/LINUX.md">
|
<a href="docs/LINUX.md">
|
||||||
LINUX.md
|
LINUX.md
|
||||||
|
30
plugin-upload.sh
Executable file
30
plugin-upload.sh
Executable file
@ -0,0 +1,30 @@
|
|||||||
|
#! /usr/bin/env sh
|
||||||
|
|
||||||
|
. ./config.sh
|
||||||
|
NUMLINE=`grep release.number build.xml | head -n 1`
|
||||||
|
sed -i "s|${NUMLINE}| <property name=\"release.number\" value=\"$GITHUB_TAG\" />|g" build.xml
|
||||||
|
ant distclean versionMd jar plugin
|
||||||
|
|
||||||
|
github-release release --user "${GITHUB_USER}" \
|
||||||
|
--repo "${GITHUB_REPO}" \
|
||||||
|
--name "${GITHUB_NAME}" \
|
||||||
|
--description "${GITHUB_DESCRIPTION}" \
|
||||||
|
--tag "${GITHUB_TAG}"; true
|
||||||
|
sleep 2s
|
||||||
|
susum=$(sha256sum i2pfirefox.su3)
|
||||||
|
github-release upload --user "${GITHUB_USER}" \
|
||||||
|
--replace \
|
||||||
|
--repo "${GITHUB_REPO}" \
|
||||||
|
--tag "${GITHUB_TAG}" \
|
||||||
|
--label "I2P Browser launcher as an I2P Console Plugin. ${susum}" \
|
||||||
|
--name "i2pfirefox.su3" \
|
||||||
|
--file "i2pfirefox.su3"
|
||||||
|
#susum=$(sha256sum i2pfirefox-update.su3)
|
||||||
|
#github-release upload --user "${GITHUB_USER}" \
|
||||||
|
# --replace \
|
||||||
|
# --repo "${GITHUB_REPO}" \
|
||||||
|
# --tag "${GITHUB_TAG}" \
|
||||||
|
# --label "I2P Browser launcher as an I2P Console Plugin, update-only. ${susum}" \
|
||||||
|
# --name "i2pfirefox-update.su3" \
|
||||||
|
# --file "i2pfirefox-update.su3"
|
||||||
|
echo "Uploaded su3 package"
|
@ -1,3 +1,3 @@
|
|||||||
#Build Number for ANT. Do not edit!
|
#Build Number for ANT. Do not edit!
|
||||||
#Thu Mar 07 12:01:15 EST 2024
|
#Mon Jul 08 17:35:59 EDT 2024
|
||||||
build.number=707
|
build.number=726
|
||||||
|
@ -1,27 +1,6 @@
|
|||||||
package net.i2p.i2pfirefox;
|
package net.i2p.i2pfirefox;
|
||||||
|
|
||||||
/*import java.awt.AWTException;
|
|
||||||
import java.awt.Component;
|
|
||||||
import java.awt.Image;
|
|
||||||
import java.awt.Menu;
|
|
||||||
import java.awt.MenuItem;
|
|
||||||
import java.awt.PopupMenu;
|
|
||||||
import java.awt.SystemTray;
|
|
||||||
import java.awt.Toolkit;
|
|
||||||
import java.awt.TrayIcon;
|
|
||||||
import java.awt.event.ActionEvent;
|
|
||||||
import java.awt.event.ActionListener;
|
|
||||||
import java.awt.event.MouseAdapter;
|
|
||||||
import java.awt.event.MouseEvent;
|
|
||||||
import java.awt.event.MouseListener;*/
|
|
||||||
import java.io.File;
|
|
||||||
import java.io.FileOutputStream;
|
|
||||||
import java.io.FileWriter;
|
|
||||||
import java.io.IOException;
|
|
||||||
import java.io.InputStream;
|
|
||||||
import java.io.OutputStream;
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Arrays;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* I2PBrowser.java
|
* I2PBrowser.java
|
||||||
@ -274,6 +253,8 @@ public class I2PBrowser extends I2PGenericUnsafeBrowser {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if (!this.chromium)
|
||||||
|
this.firefox = true;
|
||||||
}
|
}
|
||||||
return visitURL;
|
return visitURL;
|
||||||
}
|
}
|
||||||
|
@ -295,7 +295,7 @@ public class I2PChromium extends I2PChromiumProfileUnpacker {
|
|||||||
}
|
}
|
||||||
// now, do the same thing, but with user.dir instead of plugin
|
// now, do the same thing, but with user.dir instead of plugin
|
||||||
// list the directories in the user.dir directory
|
// list the directories in the user.dir directory
|
||||||
File userDir = new File(System.getProperty("user.dir"));
|
File userDir = userHomeDir();
|
||||||
if (userDir.exists()) {
|
if (userDir.exists()) {
|
||||||
if (isWindows()) {
|
if (isWindows()) {
|
||||||
File searchResult = searchFile(userDir, "ungoogled-chromium.exe");
|
File searchResult = searchFile(userDir, "ungoogled-chromium.exe");
|
||||||
|
@ -9,11 +9,9 @@ import java.io.OutputStream;
|
|||||||
import java.net.Socket;
|
import java.net.Socket;
|
||||||
import java.nio.file.Files;
|
import java.nio.file.Files;
|
||||||
import java.nio.file.StandardCopyOption;
|
import java.nio.file.StandardCopyOption;
|
||||||
import java.util.Arrays;
|
|
||||||
import java.util.Properties;
|
import java.util.Properties;
|
||||||
import java.util.logging.FileHandler;
|
import java.util.logging.FileHandler;
|
||||||
import java.util.logging.Logger;
|
import java.util.logging.Logger;
|
||||||
import java.util.logging.SimpleFormatter;
|
|
||||||
import java.util.zip.ZipEntry;
|
import java.util.zip.ZipEntry;
|
||||||
import java.util.zip.ZipInputStream;
|
import java.util.zip.ZipInputStream;
|
||||||
|
|
||||||
@ -36,6 +34,7 @@ public class I2PCommonBrowser {
|
|||||||
private Properties prop = new Properties();
|
private Properties prop = new Properties();
|
||||||
public Logger logger = Logger.getLogger("browserlauncher");
|
public Logger logger = Logger.getLogger("browserlauncher");
|
||||||
private FileHandler fh;
|
private FileHandler fh;
|
||||||
|
private boolean validated = false;
|
||||||
int CONFIGURED_TIMEOUT = 200;
|
int CONFIGURED_TIMEOUT = 200;
|
||||||
|
|
||||||
public I2PCommonBrowser() {
|
public I2PCommonBrowser() {
|
||||||
@ -75,6 +74,8 @@ public class I2PCommonBrowser {
|
|||||||
* @return None No return value.
|
* @return None No return value.
|
||||||
*/
|
*/
|
||||||
public void validateUserDirectory() {
|
public void validateUserDirectory() {
|
||||||
|
if (validated)
|
||||||
|
return;
|
||||||
logger.info("Validating user directory");
|
logger.info("Validating user directory");
|
||||||
String userDir = System.getProperty("user.dir");
|
String userDir = System.getProperty("user.dir");
|
||||||
String userHome = System.getProperty("user.home");
|
String userHome = System.getProperty("user.home");
|
||||||
@ -123,6 +124,7 @@ public class I2PCommonBrowser {
|
|||||||
logger.info(defaultPathFile.getAbsolutePath());
|
logger.info(defaultPathFile.getAbsolutePath());
|
||||||
}
|
}
|
||||||
System.setProperty("user.dir", defaultPathFile.getAbsolutePath());
|
System.setProperty("user.dir", defaultPathFile.getAbsolutePath());
|
||||||
|
validated = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -192,15 +194,17 @@ public class I2PCommonBrowser {
|
|||||||
*
|
*
|
||||||
* @return the log file for the browser launcher
|
* @return the log file for the browser launcher
|
||||||
*/
|
*/
|
||||||
/*private File logFile() {
|
/*
|
||||||
// validateUserDirectory();
|
* private File logFile() {
|
||||||
String userDirectory = System.getProperty("user.dir");
|
* // validateUserDirectory();
|
||||||
File logDirectory = new File(userDirectory, "logs");
|
* String userDirectory = System.getProperty("user.dir");
|
||||||
if (!logDirectory.exists()) {
|
* File logDirectory = new File(userDirectory, "logs");
|
||||||
logDirectory.mkdirs();
|
* if (!logDirectory.exists()) {
|
||||||
}
|
* logDirectory.mkdirs();
|
||||||
return new File(logDirectory, "browserlauncher.log");
|
* }
|
||||||
}*/
|
* return new File(logDirectory, "browserlauncher.log");
|
||||||
|
* }
|
||||||
|
*/
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the runtime directory, creating it if create=true.
|
* Get the runtime directory, creating it if create=true.
|
||||||
@ -223,7 +227,7 @@ public class I2PCommonBrowser {
|
|||||||
* Returns the runtime directory path based on the given override parameter.
|
* Returns the runtime directory path based on the given override parameter.
|
||||||
*
|
*
|
||||||
* @param override the name of the environment variable to override the
|
* @param override the name of the environment variable to override the
|
||||||
* runtime
|
* runtime
|
||||||
* directory
|
* directory
|
||||||
* @return the runtime directory path as a string
|
* @return the runtime directory path as a string
|
||||||
*/
|
*/
|
||||||
@ -586,6 +590,13 @@ public class I2PCommonBrowser {
|
|||||||
* @return the found file or null if not found
|
* @return the found file or null if not found
|
||||||
*/
|
*/
|
||||||
public File searchFile(File directory, String search) {
|
public File searchFile(File directory, String search) {
|
||||||
|
File hd = new File(System.getProperty("user.home"));
|
||||||
|
if (hd != null) {
|
||||||
|
if (directory.getAbsolutePath().equals(hd.getAbsolutePath()))
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
if (directory == null || !directory.exists() || !directory.canRead())
|
||||||
|
return null;
|
||||||
if (directory.isDirectory()) {
|
if (directory.isDirectory()) {
|
||||||
File[] files = directory.listFiles();
|
File[] files = directory.listFiles();
|
||||||
for (File file : files) {
|
for (File file : files) {
|
||||||
@ -600,4 +611,18 @@ public class I2PCommonBrowser {
|
|||||||
}
|
}
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public File userHomeDir() {
|
||||||
|
File rd = new File(System.getProperty("user.dir"));
|
||||||
|
File hd = new File(System.getProperty("user.home"));
|
||||||
|
if (rd == null || !rd.exists()) {
|
||||||
|
if (hd == null || !hd.exists()) {
|
||||||
|
if (rd.getAbsolutePath().equals(hd.getAbsolutePath()))
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
return rd;
|
||||||
|
}
|
||||||
|
logger.info("Runtime directory discovered at: " + rd);
|
||||||
|
return rd;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -292,7 +292,7 @@ public class I2PFirefox extends I2PFirefoxProfileUnpacker {
|
|||||||
}
|
}
|
||||||
// now, do the same thing, but with user.dir instead of plugin
|
// now, do the same thing, but with user.dir instead of plugin
|
||||||
// list the directories in the user.dir directory
|
// list the directories in the user.dir directory
|
||||||
File userDir = new File(System.getProperty("user.dir"));
|
File userDir = userHomeDir();
|
||||||
if (userDir.exists()) {
|
if (userDir.exists()) {
|
||||||
if (isWindows()) {
|
if (isWindows()) {
|
||||||
File searchResult = searchFile(userDir, "firefox-esr.exe");
|
File searchResult = searchFile(userDir, "firefox-esr.exe");
|
||||||
|
@ -4,7 +4,6 @@ import java.io.File;
|
|||||||
import java.io.FileOutputStream;
|
import java.io.FileOutputStream;
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.io.OutputStream;
|
import java.io.OutputStream;
|
||||||
import java.net.Socket;
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
@ -1,8 +1,5 @@
|
|||||||
package net.i2p.i2pfirefox;
|
package net.i2p.i2pfirefox;
|
||||||
|
|
||||||
import java.io.*;
|
|
||||||
import javax.script.*;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* I2PLibreWolf.java
|
* I2PLibreWolf.java
|
||||||
* Copyright (C) 2022 idk <hankhill19580@gmail.com>
|
* Copyright (C) 2022 idk <hankhill19580@gmail.com>
|
||||||
|
@ -44,6 +44,10 @@ public class I2PBrowserPlugin extends I2PBrowser implements ClientApp {
|
|||||||
private final File profileDir;
|
private final File profileDir;
|
||||||
private MenuHandle lmhs;
|
private MenuHandle lmhs;
|
||||||
private MenuHandle lmhf;
|
private MenuHandle lmhf;
|
||||||
|
/**
|
||||||
|
* @since 1.4.0
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
public I2PBrowserPlugin() {
|
public I2PBrowserPlugin() {
|
||||||
_context = new I2PAppContext();
|
_context = new I2PAppContext();
|
||||||
_mgr = null;
|
_mgr = null;
|
||||||
@ -52,6 +56,10 @@ public class I2PBrowserPlugin extends I2PBrowser implements ClientApp {
|
|||||||
pluginDir = new File(_context.getAppDir(), "plugins/i2pfirefox/");
|
pluginDir = new File(_context.getAppDir(), "plugins/i2pfirefox/");
|
||||||
profileDir = new File(pluginDir, "profile/");
|
profileDir = new File(pluginDir, "profile/");
|
||||||
}
|
}
|
||||||
|
/**
|
||||||
|
* @since 1.4.0
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
public I2PBrowserPlugin(I2PAppContext ctx, ClientAppManager mgr,
|
public I2PBrowserPlugin(I2PAppContext ctx, ClientAppManager mgr,
|
||||||
String args[]) {
|
String args[]) {
|
||||||
_context = ctx;
|
_context = ctx;
|
||||||
@ -61,9 +69,26 @@ public class I2PBrowserPlugin extends I2PBrowser implements ClientApp {
|
|||||||
pluginDir = new File(_context.getAppDir(), "plugins/i2pfirefox/");
|
pluginDir = new File(_context.getAppDir(), "plugins/i2pfirefox/");
|
||||||
profileDir = new File(pluginDir, "profile/");
|
profileDir = new File(pluginDir, "profile/");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @since 1.4.0
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
public String getDisplayName() { return "I2P Browser"; }
|
public String getDisplayName() { return "I2P Browser"; }
|
||||||
|
/**
|
||||||
|
* @since 1.4.0
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
public String getName() { return "I2P Browser"; }
|
public String getName() { return "I2P Browser"; }
|
||||||
|
/**
|
||||||
|
* @since 1.4.0
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
public ClientAppState getState() { return ClientAppState.STOPPED; }
|
public ClientAppState getState() { return ClientAppState.STOPPED; }
|
||||||
|
/**
|
||||||
|
* @since 1.4.0
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
public void shutdown(String[] args) {
|
public void shutdown(String[] args) {
|
||||||
if (!isSystrayEnabled()) {
|
if (!isSystrayEnabled()) {
|
||||||
_log.info("I2P Browser tray manager not supported");
|
_log.info("I2P Browser tray manager not supported");
|
||||||
@ -81,6 +106,10 @@ public class I2PBrowserPlugin extends I2PBrowser implements ClientApp {
|
|||||||
}
|
}
|
||||||
changeState(ClientAppState.STOPPED);
|
changeState(ClientAppState.STOPPED);
|
||||||
}
|
}
|
||||||
|
/**
|
||||||
|
* @since 1.4.0
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
public void startup() {
|
public void startup() {
|
||||||
changeState(ClientAppState.STOPPED);
|
changeState(ClientAppState.STOPPED);
|
||||||
if (!isSystrayEnabled()) {
|
if (!isSystrayEnabled()) {
|
||||||
@ -98,15 +127,17 @@ public class I2PBrowserPlugin extends I2PBrowser implements ClientApp {
|
|||||||
"Starting I2P Browser tray manager by testing http://proxy.i2p");
|
"Starting I2P Browser tray manager by testing http://proxy.i2p");
|
||||||
MenuService dtg = startTrayApp();
|
MenuService dtg = startTrayApp();
|
||||||
try {
|
try {
|
||||||
Thread.sleep(1000);
|
Thread.sleep(5000);
|
||||||
} catch (InterruptedException ie) {
|
} catch (InterruptedException ie) {
|
||||||
}
|
}
|
||||||
if (dtg != null) {
|
if (dtg != null) {
|
||||||
_log.info("I2P Browser integrating with I2P tray manager");
|
_log.info("I2P Browser integrating with I2P tray manager");
|
||||||
lmhs = dtg.addMenu("Launch I2P Browser (Safe Mode)", new Starter(dtg));
|
lmhs =
|
||||||
|
dtg.addMenu("Launch I2P Browser (Safe Mode)", new Starter(dtg));
|
||||||
dtg.showMenu(lmhs);
|
dtg.showMenu(lmhs);
|
||||||
dtg.enableMenu(lmhs);
|
dtg.enableMenu(lmhs);
|
||||||
lmhf = dtg.addMenu("Launch I2P Browser (Flexible Mode)", new FlexStarter(dtg));
|
lmhf = dtg.addMenu("Launch I2P Browser (Flexible Mode)",
|
||||||
|
new FlexStarter(dtg));
|
||||||
dtg.showMenu(lmhf);
|
dtg.showMenu(lmhf);
|
||||||
dtg.enableMenu(lmhf);
|
dtg.enableMenu(lmhf);
|
||||||
} else {
|
} else {
|
||||||
@ -122,6 +153,10 @@ public class I2PBrowserPlugin extends I2PBrowser implements ClientApp {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Copied directly from I2PSnark-standalone
|
// Copied directly from I2PSnark-standalone
|
||||||
|
/**
|
||||||
|
* @since 1.4.0
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
private MenuService startTrayApp() {
|
private MenuService startTrayApp() {
|
||||||
try {
|
try {
|
||||||
if (isSystrayEnabled()) {
|
if (isSystrayEnabled()) {
|
||||||
@ -141,6 +176,10 @@ public class I2PBrowserPlugin extends I2PBrowser implements ClientApp {
|
|||||||
// whether to launchFirefox the tray app Our environment should basically
|
// whether to launchFirefox the tray app Our environment should basically
|
||||||
// never be headless, that doesn't make any sense, but something tells me I
|
// never be headless, that doesn't make any sense, but something tells me I
|
||||||
// should leave that check in.
|
// should leave that check in.
|
||||||
|
/**
|
||||||
|
* @since 1.4.0
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
private boolean isSystrayEnabled() {
|
private boolean isSystrayEnabled() {
|
||||||
if (GraphicsEnvironment.isHeadless())
|
if (GraphicsEnvironment.isHeadless())
|
||||||
return false;
|
return false;
|
||||||
@ -151,14 +190,16 @@ public class I2PBrowserPlugin extends I2PBrowser implements ClientApp {
|
|||||||
// Ubuntu GNOME does not work, SystemTray.isSupported() returns false
|
// Ubuntu GNOME does not work, SystemTray.isSupported() returns false
|
||||||
String xdg = System.getenv("XDG_CURRENT_DESKTOP");
|
String xdg = System.getenv("XDG_CURRENT_DESKTOP");
|
||||||
boolean dflt = SystemVersion.isWindows() || SystemVersion.isMac() ||
|
boolean dflt = SystemVersion.isWindows() || SystemVersion.isMac() ||
|
||||||
//"XFCE".equals(xdg) ||
|
"XFCE".equals(xdg) ||
|
||||||
"KDE".equals(xdg) || "LXDE".equals(xdg);
|
"KDE".equals(xdg) || "LXDE".equals(xdg);
|
||||||
return _context.getProperty(PROP_DTG_ENABLED, dflt);
|
return _context.getProperty(PROP_DTG_ENABLED, dflt);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Callback when Start I2PBrowser is clicked in systray
|
* Callback when Start I2PBrowser is clicked in systray
|
||||||
* @since 0.9.61
|
*
|
||||||
|
* @since 1.4.0
|
||||||
|
* @return
|
||||||
*/
|
*/
|
||||||
public class Starter implements MenuCallback {
|
public class Starter implements MenuCallback {
|
||||||
private final MenuService _ms;
|
private final MenuService _ms;
|
||||||
@ -179,9 +220,13 @@ public class I2PBrowserPlugin extends I2PBrowser implements ClientApp {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @since 1.4.0
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
public class FlexStarter implements MenuCallback {
|
public class FlexStarter implements MenuCallback {
|
||||||
private final MenuService _ms;
|
private final MenuService _ms;
|
||||||
public Starter(MenuService ms) { _ms = ms; }
|
public FlexStarter(MenuService ms) { _ms = ms; }
|
||||||
public void clicked(MenuHandle menu) {
|
public void clicked(MenuHandle menu) {
|
||||||
// Thread t = new I2PAppThread(new StarterThread(),
|
// Thread t = new I2PAppThread(new StarterThread(),
|
||||||
//"I2PBrowser-Launcher start", true);
|
//"I2PBrowser-Launcher start", true);
|
||||||
@ -199,20 +244,10 @@ public class I2PBrowserPlugin extends I2PBrowser implements ClientApp {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public class StarterThread implements Runnable {
|
/**
|
||||||
public void run() {
|
* @since 1.4.0
|
||||||
_log.info("I2P Browser starting up");
|
* @return
|
||||||
try {
|
*/
|
||||||
I2PBrowser i2pBrowser = new I2PBrowser(profileDir.getAbsolutePath());
|
|
||||||
String[] args = {"http://proxy.i2p"};
|
|
||||||
i2pBrowser.launchFirefox(0, args);
|
|
||||||
} catch (Exception e) {
|
|
||||||
_log.error("Error starting I2P Browser", e);
|
|
||||||
}
|
|
||||||
_log.info("I2P Browser ran");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private synchronized void changeState(ClientAppState state) {
|
private synchronized void changeState(ClientAppState state) {
|
||||||
if (_mgr != null)
|
if (_mgr != null)
|
||||||
_mgr.notify(this, state, null, null);
|
_mgr.notify(this, state, null, null);
|
||||||
|
Reference in New Issue
Block a user