Skip to content

Commit 6816410

Browse files
authored
Merge branch 'master' into jeremypw/rework-highlight-selection
2 parents 2a7161d + 72bb50c commit 6816410

33 files changed

+209
-160
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ jobs:
5858
uses: flatpak/flatpak-github-actions/flatpak-builder@v6
5959
with:
6060
bundle: code.flatpak
61-
manifest-path: io.elementary.code.yml
61+
manifest-path: com.github.jeremypw.dogfood-code-7.yml
6262
repository-name: appcenter
6363
repository-url: https://flatpak.elementary.io/repo.flatpakrepo
6464
cache-key: "flatpak-builder-${{ github.sha }}"

README.md

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
1-
# Code
2-
[![Translation status](https://l10n.elementary.io/widgets/code/-/svg-badge.svg)](https://l10n.elementary.io/projects/code/?utm_source=widget)
3-
1+
# Dogfood-code-7
42
![Screenshot](data/screenshot.png?raw=true)
53

64
## Building, Testing, and Installation
@@ -27,7 +25,7 @@ Run `meson build` to configure the build environment. Change to the build direct
2725
cd build
2826
ninja test
2927

30-
To install, use `ninja install`, then execute with `io.elementary.code`
28+
To install, use `ninja install`, then execute with `com.github.jeremypw.dogfood-code-7`
3129

3230
sudo ninja install
33-
io.elementary.code
31+
com.github.jeremypw.dogfood-code-7

data/code.policy.in.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
<vendor>elementary</vendor>
77
<vendor_url>https://github.com/elementary/code</vendor_url>
88
<icon_name>io.elementary.code</icon_name>
9-
<action id="org.freedesktop.policykit.pkexec.io.elementary.code">
9+
<action id="org.freedesktop.policykit.pkexec.com.github.jeremypw.dogfood-code-7">
1010
<description>Run Code as Administrator</description>
1111
<message>Authentication is required to run Code as Administrator</message>
1212
<defaults>

data/io.elementary.code.desktop.in.in

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
[Desktop Entry]
22
Type=Application
33
Name=@NAME@
4-
Comment=Edit code files
5-
GenericName=Code Editor
4+
Comment=Dogfood Code editor on eOS7
5+
GenericName=Experimental Code Editor
66
Exec=@EXEC_NAME@ %U
7-
Icon=io.elementary.code
7+
Icon=missing-image
88
Terminal=false
99
Categories=Development;GTK;IDE;WebDevelopment;
1010
Keywords=text;IDE;scratch;code;

data/io.elementary.code.gschema.xml

Lines changed: 15 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,24 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<schemalist>
3-
<enum id="io.elementary.code.window-states">
3+
<enum id="com.github.jeremypw.dogfood-code-7.window-states">
44
<value nick="Normal" value="0" />
55
<value nick="Maximized" value="1" />
66
<value nick="Fullscreen" value="2" />
77
</enum>
8-
<enum id="io.elementary.code.draw-spaces-states">
8+
<enum id="com.github.jeremypw.dogfood-code-7.draw-spaces-states">
99
<value nick="Never" value="0" />
1010
<value nick="For Selection" value="1" />
1111
<value nick="Always" value="2" />
1212
<value nick="Current" value="4" />
1313
</enum>
14-
<enum id="io.elementary.code.case-sensitive-mode">
14+
<enum id="com.github.jeremypw.dogfood-code-7.case-sensitive-mode">
1515
<value nick="never" value="0" />
1616
<value nick="mixed" value="1" />
1717
<value nick="always" value="2" />
1818
</enum>
1919

20-
<schema path="/io/elementary/code/saved-state/" id="io.elementary.code.saved-state" gettext-domain="io.elementary.code">
21-
<key name="window-state" enum="io.elementary.code.window-states">
20+
<schema path="/com/github/jeremypw/dogfood-code-7/saved-state/" id="com.github.jeremypw.dogfood-code-7.saved-state" gettext-domain="com.github.jeremypw.dogfood-code-7">
21+
<key name="window-state" enum="com.github.jeremypw.dogfood-code-7.window-states">
2222
<default>"Normal"</default>
2323
<summary>The saved state of the window.</summary>
2424
<description>The saved state of the window.</description>
@@ -65,7 +65,7 @@
6565
</key>
6666
</schema>
6767

68-
<schema path="/io/elementary/code/settings/" id="io.elementary.code.settings" gettext-domain="io.elementary.code">
68+
<schema path="/com/github/jeremypw/dogfood-code-7/" id="com.github.jeremypw.dogfood-code-7.settings" gettext-domain="com.github.jeremypw.dogfood-code-7">
6969
<key type="as" name="plugins-enabled">
7070
<default>['brackets-completion', 'detect-indent', 'editorconfig']</default>
7171
<summary>Enabled Plugins</summary>
@@ -106,7 +106,7 @@
106106
<summary>Highlight Matching Brackets</summary>
107107
<description>Whether Code should highlight matching brackets.</description>
108108
</key>
109-
<key name="draw-spaces" enum="io.elementary.code.draw-spaces-states">
109+
<key name="draw-spaces" enum="com.github.jeremypw.dogfood-code-7.draw-spaces-states">
110110
<default>"For Selection"</default>
111111
<summary>Draw spaces and tabs with symbols</summary>
112112
<description>Draw spaces and tabs with symbols. "Never" is deprecated and not exposed in the UI.</description>
@@ -152,6 +152,11 @@
152152
<summary>Remember the last focused document.</summary>
153153
<description>Restore the focused document from a previous session when opening Code.</description>
154154
</key>
155+
<key name="active-project-path" type="s">
156+
<default>''</default>
157+
<summary>The active project path.</summary>
158+
<description>The path to the folder containing the active project.</description>
159+
</key>
155160
<key name="default-build-directory" type="s">
156161
<default>''</default>
157162
<summary>The default build directory's relative path.</summary>
@@ -182,7 +187,7 @@
182187
<summary>Whether search term is a regex expression</summary>
183188
<description>Whether the search should use the search term as a regex expression for matching.</description>
184189
</key>
185-
<key name="case-sensitive-search" enum="io.elementary.code.case-sensitive-mode">
190+
<key name="case-sensitive-search" enum="com.github.jeremypw.dogfood-code-7.case-sensitive-mode">
186191
<default>'mixed'</default>
187192
<summary>When text search is case sensitive</summary>
188193
<description>Whether the text search is case sensitive never, always or only when search term is mixed case</description>
@@ -194,7 +199,7 @@
194199
</key>
195200
</schema>
196201

197-
<schema path="/io/elementary/code/services/" id="io.elementary.code.services" gettext-domain="io.elementary.code">
202+
<schema path="/com/github/jeremypw/dogfood-code-7/services/" id="com.github.jeremypw.dogfood-code-7.services" gettext-domain="com.github.jeremypw.dogfood-code-7">
198203
<key name="paste-format-code" type="s">
199204
<default>'None'</default>
200205
<summary>Default PasteBin text highlight</summary>
@@ -212,7 +217,7 @@
212217
</key>
213218
</schema>
214219

215-
<schema path="/io/elementary/code/folder-manager/" id="io.elementary.code.folder-manager">
220+
<schema path="/com/github/jeremypw/dogfood-code-7/folder-manager/" id="com.github.jeremypw.dogfood-code-7.folder-manager">
216221
<key name="opened-folders" type="as">
217222
<default>[]</default>
218223
<summary>Opened folders.</summary>

data/io.elementary.code.plugins.spell.gschema.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<schemalist>
3-
<schema path="/io/elementary/code/plugins/spell/" id="io.elementary.code.plugins.spell">
3+
<schema path="/com/github/jeremypw/dogfood-code-7/plugins/spell/" id="com.github.jeremypw.dogfood-code-7.plugins.spell">
44
<key name="language" type="s">
55
<default>'en_US'</default>
66
<summary>Selected Spellcheck Language</summary>

data/meson.build

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,12 @@ foreach i : icon_sizes
44
install_data(
55
'icons' / i + '.svg',
66
install_dir: get_option('datadir') / 'icons' / 'hicolor' / i + 'x' + i / 'apps',
7-
rename: meson.project_name() + '.svg'
7+
rename: install_name + '.svg'
88
)
99
install_data(
1010
'icons' / i + '.svg',
1111
install_dir: get_option('datadir') / 'icons' / 'hicolor' / i + 'x' + i + '@2' / 'apps',
12-
rename: meson.project_name() + '.svg'
12+
rename: install_name + '.svg'
1313
)
1414
endforeach
1515

@@ -20,7 +20,7 @@ install_data([
2020

2121
install_data([
2222
'fonts/BuilderBlocks.ttf',
23-
], install_dir: get_option('datadir') / meson.project_name() / 'fonts')
23+
], install_dir: get_option('datadir') / install_name / 'fonts')
2424

2525
install_data(
2626
'io.elementary.code.gschema.xml',
@@ -29,12 +29,12 @@ install_data(
2929
)
3030

3131
config_data = configuration_data()
32-
config_data.set('EXEC_NAME', meson.project_name())
32+
config_data.set('EXEC_NAME', install_name)
3333

3434
if (branch != '')
35-
config_data.set('NAME', 'Code - ' + branch)
35+
config_data.set('NAME', 'Dogfood Code 7 - ' + branch)
3636
else
37-
config_data.set('NAME', 'Code')
37+
config_data.set('NAME', 'Dogfood Code 7')
3838
endif
3939

4040
# Set the executable name and translate the desktop files
@@ -46,7 +46,7 @@ desktop_in_file = configure_file(
4646

4747
desktop_file = i18n.merge_file(
4848
input: desktop_in_file,
49-
output: 'io.elementary.code.desktop',
49+
output: install_name + '.desktop',
5050
po_dir: meson.project_source_root () / 'po' / 'extra',
5151
type: 'desktop',
5252
install_dir: get_option('datadir') / 'applications',
@@ -55,7 +55,7 @@ desktop_file = i18n.merge_file(
5555

5656
i18n.merge_file(
5757
input: 'code.metainfo.xml.in',
58-
output: meson.project_name() + '.metainfo.xml',
58+
output: install_name + '.metainfo.xml',
5959
po_dir: meson.project_source_root() / 'po' / 'extra',
6060
type: 'xml',
6161
install: true,
@@ -65,19 +65,19 @@ i18n.merge_file(
6565
config_data = configuration_data()
6666
config_data.set('install_prefix', get_option('prefix'))
6767
config_data.set('bin_dir', get_option('bindir'))
68-
config_data.set('exec_name', meson.project_name())
68+
config_data.set('exec_name', install_name)
6969

7070
if get_option ('have_pkexec')
7171
policy_in = configure_file(
7272
input: 'code.policy.in.in',
73-
output: meson.project_name() + '.policy.in',
73+
output: install_name + '.policy.in',
7474
configuration: config_data,
7575
install: false,
7676
)
7777

7878
i18n.merge_file(
7979
input: policy_in,
80-
output: meson.project_name() + '.policy',
80+
output: install_name + '.policy',
8181
po_dir: meson.project_source_root () / 'po' / 'extra',
8282
install: true,
8383
install_dir: get_option('datadir') / 'polkit-1' / 'actions',

io.elementary.code.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
app-id: io.elementary.code
1+
app-id: com.github.jeremypw.dogfood-code-7
22
runtime: io.elementary.Sdk # The outline plugin requires libvala which is only in the SDK, not the runtime
33
runtime-version: '7.1'
44
sdk: io.elementary.Sdk
5-
command: io.elementary.code
5+
command: com.github.jeremypw.dogfood-code-7
66
finish-args:
77
- '--filesystem=xdg-run/gvfsd'
88
- '--filesystem=host'

meson.build

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,16 @@
1+
# Original project from which fork was made
12
project(
23
'io.elementary.code',
34
'vala', 'c',
45
meson_version: '>= 0.58.0',
56
version: '7.4.0'
67
)
78

9+
# Install under different name so may be run alongside original
10+
install_name = 'com.github.jeremypw.dogfood-code-7'
11+
812
add_project_arguments([
9-
'-DGETTEXT_PACKAGE="@0@"'.format(meson.project_name())
13+
'-DGETTEXT_PACKAGE="@0@"'.format(install_name)
1014
],
1115
language: 'c',
1216
)
@@ -20,8 +24,8 @@ if get_option('have_pkexec')
2024
add_project_arguments('--define=HAVE_PKEXEC', language: 'vala')
2125
endif
2226

23-
libexecdir = get_option('prefix') / get_option('libexecdir') / meson.project_name()
24-
pluginsdir = get_option('prefix') / get_option('libdir') / meson.project_name() / 'plugins'
27+
libexecdir = get_option('prefix') / get_option('libexecdir') / install_name
28+
pluginsdir = get_option('prefix') / get_option('libdir') / install_name / 'plugins'
2529

2630
gnome = import('gnome')
2731
i18n = import('i18n')

meson_options.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
option ('plugins', type : 'boolean', value : true)
22
option('have_pkexec', type : 'boolean', value : 'true', description : 'Allow launching with pkexec. Should not be used in FlatPak')
3-
option('development', type : 'boolean', value : false, description : 'Build is a development branch')
3+
option('development', type : 'boolean', value : 'true', description : 'Build is a development branch')

0 commit comments

Comments
 (0)