Skip to content

Commit

Permalink
Run our profile loader from doomscript wrapper
Browse files Browse the repository at this point in the history
Should have no impact unless the user initializes Doom from a
doomscript. If they use our wrapper to do that, assume they want our
profile to work.

Remove some duplication while I'm there.
  • Loading branch information
marienz committed Dec 30, 2024
1 parent 0d1789c commit b965bd2
Showing 1 changed file with 6 additions and 8 deletions.
14 changes: 6 additions & 8 deletions build-helpers/build-doom-emacs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,21 +14,19 @@
# See the License for the specific language governing permissions and
# limitations under the License.

profileArgs=(
commonArgs=(
--set DOOMPROFILELOADFILE $doomProfile/loader/init
--set DOOMPROFILE "$profileName"
--set-default DOOMLOCALDIR "$doomLocalDir"
--set DOOMDIR $doomProfile/doomdir
)

makeWrapper $emacsWithPackages/bin/emacs $out/bin/doom-emacs \
"${profileArgs[@]}" \
--set DOOMDIR $doomProfile/doomdir \
--set-default DOOMLOCALDIR "$doomLocalDir" \
"${commonArgs[@]}" \
--add-flags "--init-directory=$doomSource"
makeWrapper $doomSource/bin/doomscript $out/bin/doomscript \
--set EMACS $emacsWithPackages/bin/emacs \
--set-default DOOMLOCALDIR "$doomLocalDir"
"${commonArgs[@]}"
makeWrapper $doomSource/bin/doom $out/bin/doom \
--set EMACS $emacsWithPackages/bin/emacs \
"${profileArgs[@]}" \
--set DOOMDIR $doomProfile/doomdir \
--set-default DOOMLOCALDIR "$doomLocalDir"
"${commonArgs[@]}"

0 comments on commit b965bd2

Please sign in to comment.