cleanup & change binary name to rosenrot
This commit is contained in:
parent
94326a8cad
commit
d6456e4357
6
TODO.md
6
TODO.md
|
@ -3,21 +3,21 @@
|
||||||
## Quality of life:
|
## Quality of life:
|
||||||
|
|
||||||
- [ ] Document creating new applications, e.g., as in [Asana for Linux](https://git.nunosempere.com/NunoSempere/asana-for-linux)
|
- [ ] Document creating new applications, e.g., as in [Asana for Linux](https://git.nunosempere.com/NunoSempere/asana-for-linux)
|
||||||
- [ ] Set [`webkit_web_context_set_sandbox_enabled`](<https://webkitgtk.org/reference/webkit2gtk/2.36.8/WebKitWebContext.html#webkit-web-context-set-sandbox-enabled>), as recommended [here](<https://blogs.gnome.org/mcatanzaro/2022/11/04/stop-using-qtwebkit/>)
|
|
||||||
- [ ] Use something other than Whatsapp as an example syslink.
|
- [ ] Use something other than Whatsapp as an example syslink.
|
||||||
- [ ] Fix bug about distorted audio. Maybe related to [this pipewire issue](<https://gitlab.freedesktop.org/pipewire/pipewire/-/issues/1547>)?
|
- [ ] Fix bug about distorted audio. Maybe related to [this pipewire issue](<https://gitlab.freedesktop.org/pipewire/pipewire/-/issues/1547>)?
|
||||||
- [ ] Upgrade to GTK-4 / Webkitgtk 6.0? Will take a fair amount of time, since these are not available on Ubuntu 20.04.
|
- [ ] Upgrade to GTK-4 / Webkitgtk 6.0? Will take a fair amount of time, since GTK4 redesigns the application model somewhat.
|
||||||
- Instructions for webkit-6.0 [here](https://github.com/WebKit/WebKit/blob/ed1422596dce5ff012e64a38faf402ac1674fc7e/Source/WebKit/gtk/migrating-to-webkitgtk-6.0.md)
|
- Instructions for webkit-6.0 [here](https://github.com/WebKit/WebKit/blob/ed1422596dce5ff012e64a38faf402ac1674fc7e/Source/WebKit/gtk/migrating-to-webkitgtk-6.0.md)
|
||||||
- Instructions for GTK-4 [here](https://docs.gtk.org/gtk4/migrating-3to4.html)
|
- Instructions for GTK-4 [here](https://docs.gtk.org/gtk4/migrating-3to4.html)
|
||||||
- [ ] Prepare for GTK-3 to GTK-4 transition
|
- [ ] Prepare for GTK-3 to GTK-4 transition
|
||||||
- [ ] Understand wtf is going on with signals and events: <https://docs.gtk.org/gtk4/migrating-3to4.html#stop-using-gtkwidget-event-signals>. <https://github.com/mini-rose/rose-browser/blob/288bf060d095c4895946669ae50d14193168b69c/src/window.c#L42>
|
- [ ] Understand wtf is going on with signals and events: <https://docs.gtk.org/gtk4/migrating-3to4.html#stop-using-gtkwidget-event-signals>. <https://github.com/mini-rose/rose-browser/blob/288bf060d095c4895946669ae50d14193168b69c/src/window.c#L42>
|
||||||
- [ ] Remove webkit2gtk-4.1 and download webkit2gtk-6.0
|
- [ ] Remove webkit2gtk-4.1 and download webkit2gtk-6.0
|
||||||
- [ ] Attempt to compile
|
- [ ] Attempt to compile
|
||||||
- [ ] Change README and point to last Ubuntu 20.04 commit
|
|
||||||
|
|
||||||
# Previously done
|
# Previously done
|
||||||
|
|
||||||
|
- ~~[ ] Set [`webkit_web_context_set_sandbox_enabled`](<https://webkitgtk.org/reference/webkit2gtk/2.36.8/WebKitWebContext.html#webkit-web-context-set-sandbox-enabled>), as recommended [here](<https://blogs.gnome.org/mcatanzaro/2022/11/04/stop-using-qtwebkit/>)~~. Irrelevant with upgrade to libsoup3.
|
||||||
- [x] Update to webkit2gtk-4.1
|
- [x] Update to webkit2gtk-4.1
|
||||||
|
- [x] Change README and point to last Ubuntu 20.04 commit
|
||||||
- [x] Add list of similar projects: <https://github.com/qutebrowser/qutebrowser#similar-projects>
|
- [x] Add list of similar projects: <https://github.com/qutebrowser/qutebrowser#similar-projects>
|
||||||
- [x] Add comparisons against rose & surf
|
- [x] Add comparisons against rose & surf
|
||||||
- [x] Compare against rose
|
- [x] Compare against rose
|
||||||
|
|
2
config.h
2
config.h
|
@ -43,7 +43,7 @@ To remove plugins completely;
|
||||||
"enable-smooth-scrolling", false, \
|
"enable-smooth-scrolling", false, \
|
||||||
"default-charset", "utf-8"
|
"default-charset", "utf-8"
|
||||||
/* CACHE */
|
/* CACHE */
|
||||||
#define DATA_DIR "/home/nuno/.cache/rose"
|
#define DATA_DIR "/home/nuno/.cache/rosenrot"
|
||||||
#define DATA_MANAGER_OPTS "base-cache-directory", DATA_DIR, "base-data-directory", DATA_DIR
|
#define DATA_MANAGER_OPTS "base-cache-directory", DATA_DIR, "base-data-directory", DATA_DIR
|
||||||
|
|
||||||
// GTK
|
// GTK
|
||||||
|
|
44
makefile
44
makefile
|
@ -12,7 +12,7 @@ INCS=`pkg-config --cflags ${DEPS}`
|
||||||
LIBS=`pkg-config --libs ${DEPS}`
|
LIBS=`pkg-config --libs ${DEPS}`
|
||||||
|
|
||||||
# Code
|
# Code
|
||||||
SRC=rose.c
|
SRC=rosenrot.c
|
||||||
CONFIG=config.h
|
CONFIG=config.h
|
||||||
|
|
||||||
## Plugins
|
## Plugins
|
||||||
|
@ -31,8 +31,8 @@ FORMATTER=clang-format -i -style=$(STYLE_BLUEPRINT)
|
||||||
# Change hardcoded paths when building
|
# Change hardcoded paths when building
|
||||||
## Data dirs
|
## Data dirs
|
||||||
USER=`whoami`
|
USER=`whoami`
|
||||||
DEFAULT_DATA_DIR=/home/nuno/.cache/rose
|
DEFAULT_DATA_DIR=/home/nuno/.cache/rosenrot
|
||||||
USER_DATA_DIR=/home/$(USER)/.cache/rose
|
USER_DATA_DIR=/home/$(USER)/.cache/rosenrot
|
||||||
## Startup image dir
|
## Startup image dir
|
||||||
DEFAULT_DIR=/home/nuno/Documents/workspace/rosenrot
|
DEFAULT_DIR=/home/nuno/Documents/workspace/rosenrot
|
||||||
CURRENT_DIR=`pwd`
|
CURRENT_DIR=`pwd`
|
||||||
|
@ -51,50 +51,50 @@ build: $(SRC) $(PLUGINS) $(CONFIG)
|
||||||
sed -i "s|$(DEFAULT_DIR)|$(CURRENT_DIR)|g" {} +
|
sed -i "s|$(DEFAULT_DIR)|$(CURRENT_DIR)|g" {} +
|
||||||
# Compile rosenrot
|
# Compile rosenrot
|
||||||
GIO_MODULE_DIR=/usr/lib/x86_64-linux-gnu/gio/modules/
|
GIO_MODULE_DIR=/usr/lib/x86_64-linux-gnu/gio/modules/
|
||||||
$(CC) $(WARNINGS) $(OPTIMIZED_MORE) $(DEBUG) $(INCS) $(PLUGINS) $(SRC) -o rose $(LIBS) $(ADBLOCK)
|
$(CC) $(WARNINGS) $(OPTIMIZED_MORE) $(DEBUG) $(INCS) $(PLUGINS) $(SRC) -o rosenrot $(LIBS) $(ADBLOCK)
|
||||||
|
|
||||||
install: rose
|
install: rosenrot
|
||||||
GIO_MODULE_DIR=/usr/lib/x86_64-linux-gnu/gio/modules/
|
GIO_MODULE_DIR=/usr/lib/x86_64-linux-gnu/gio/modules/
|
||||||
cp -f rose /usr/bin
|
cp -f rosenrot /usr/bin
|
||||||
mkdir -p /usr/share/themes/rose
|
mkdir -p /usr/share/themes/rosenrot
|
||||||
cp style.css /usr/share/themes/rose/
|
cp style.css /usr/share/themes/rosenrot/
|
||||||
cp rose-mklink /usr/bin
|
cp rosenrot-mklink /usr/bin
|
||||||
sudo mkdir -p /usr/bin/rose-browser
|
sudo mkdir -p /usr/bin/rosenrot-browser
|
||||||
sudo cp rose /usr/bin/rose-browser/twitter # custom twitter tweaks
|
sudo cp rosenrot /usr/bin/rosenrot-browser/twitter # custom twitter tweaks
|
||||||
|
|
||||||
uninstall:
|
uninstall:
|
||||||
rm -r /usr/share/themes/rose
|
rm -r /usr/share/themes/rosenrot
|
||||||
rm /usr/bin/rose
|
rm /usr/bin/rosenrot
|
||||||
rm /usr/bin/rose-mklink
|
rm /usr/bin/rosenrot-mklink
|
||||||
rm $(DATA_DIR)
|
rm $(DATA_DIR)
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
rm rose
|
rm rosenrot
|
||||||
rm $(DATA_DIR)
|
rm $(DATA_DIR)
|
||||||
|
|
||||||
format: $(SRC) $(PLUGINS)
|
format: $(SRC) $(PLUGINS)
|
||||||
$(FORMATTER) $(SRC) $(PLUGINS) $(rose.h)
|
$(FORMATTER) $(SRC) $(PLUGINS) $(rosenrot.h)
|
||||||
|
|
||||||
lint:
|
lint:
|
||||||
clang-tidy $(SRC) $(PLUGINS) -- -Wall -O3 `pkg-config --cflags 'webkit2gtk-4.1'` -o rose `pkg-config --libs 'webkit2gtk-4.1'`
|
clang-tidy $(SRC) $(PLUGINS) -- -Wall -O3 `pkg-config --cflags 'webkit2gtk-4.1'` -o rosenrot `pkg-config --libs 'webkit2gtk-4.1'`
|
||||||
|
|
||||||
## A few more commands:
|
## A few more commands:
|
||||||
|
|
||||||
fast: $(SRC) $(PLUGINS) $(CONFIG)
|
fast: $(SRC) $(PLUGINS) $(CONFIG)
|
||||||
rm -f *.gcda
|
rm -f *.gcda
|
||||||
GIO_MODULE_DIR=/usr/lib/x86_64-linux-gnu/gio/modules/
|
GIO_MODULE_DIR=/usr/lib/x86_64-linux-gnu/gio/modules/
|
||||||
$(CC) $(WARNINGS) $(OPTIMIZED_MORE) -fprofile-generate $(INCS) $(PLUGINS) $(SRC) -o rose $(LIBS) $(ADBLOCK)
|
$(CC) $(WARNINGS) $(OPTIMIZED_MORE) -fprofile-generate $(INCS) $(PLUGINS) $(SRC) -o rosenrot $(LIBS) $(ADBLOCK)
|
||||||
@echo "Now use the browser for a while to gather some profiling data"
|
@echo "Now use the browser for a while to gather some profiling data"
|
||||||
sleep 2
|
sleep 2
|
||||||
./rose
|
./rosenrot
|
||||||
$(CC) $(WARNINGS) $(OPTIMIZED_MORE) -fprofile-use $(INCS) $(PLUGINS) $(SRC) -o rose $(LIBS) $(ADBLOCK)
|
$(CC) $(WARNINGS) $(OPTIMIZED_MORE) -fprofile-use $(INCS) $(PLUGINS) $(SRC) -o rosenrot $(LIBS) $(ADBLOCK)
|
||||||
rm -f *.gcda
|
rm -f *.gcda
|
||||||
|
|
||||||
inspect: build
|
inspect: build
|
||||||
GTK_DEBUG=interactive ./rose
|
GTK_DEBUG=interactive ./rosenrot
|
||||||
|
|
||||||
diagnose_deprecations:
|
diagnose_deprecations:
|
||||||
G_ENABLE_DIAGNOSTIC=1 ./rose
|
G_ENABLE_DIAGNOSTIC=1 ./rosenrot
|
||||||
|
|
||||||
view-gtk3-version:
|
view-gtk3-version:
|
||||||
dpkg -l libgtk-3-0
|
dpkg -l libgtk-3-0
|
||||||
|
|
BIN
rose → rosenrot
BIN
rose → rosenrot
Binary file not shown.
|
@ -1,7 +1,7 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
test "$1" = "--help" || test -z "$1" && {
|
test "$1" = "--help" || test -z "$1" && {
|
||||||
printf "%s\n" "usage: rose-mklink <alias> <url>" \
|
printf "%s\n" "usage: rosenrot-mklink <alias> <url>" \
|
||||||
"Create a /usr/bin link to a website."
|
"Create a /usr/bin link to a website."
|
||||||
exit
|
exit
|
||||||
}
|
}
|
||||||
|
@ -12,6 +12,6 @@ test -z "$2" || {
|
||||||
exit 1
|
exit 1
|
||||||
}
|
}
|
||||||
|
|
||||||
printf "#!/bin/sh\n\nrose %s" "$2" > /usr/bin/$1
|
printf "#!/bin/sh\n\nrosenrot %s" "$2" > /usr/bin/$1
|
||||||
chmod +x /usr/bin/$1
|
chmod +x /usr/bin/$1
|
||||||
}
|
}
|
|
@ -21,5 +21,5 @@ sudo make install
|
||||||
|
|
||||||
cd -
|
cd -
|
||||||
# Debian desktop icon
|
# Debian desktop icon
|
||||||
chmod +x rose.desktop
|
chmod +x rosenrot.desktop
|
||||||
sudo cp rose.desktop /usr/share/applications
|
sudo cp rosenrot.desktop /usr/share/applications
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
Code here uses the libwebkit2gtk-4.0 api. It is deprecated. See the debian version for how to use the -4.1 version instead. Package names might vary.
|
Code in this directory refers to a previous version of rosenrot which used the libwebkit2gtk-4.0 api. It is deprecated. See the debian folder for how to use the -4.1 version instead. Package names might vary.
|
||||||
|
|
Loading…
Reference in New Issue
Block a user