mirror of
https://github.com/fish-shell/fish-shell
synced 2024-12-25 12:23:09 +00:00
Fix fish_config in .app
* Copy docs into Resrouces * Export $__fish_bin_dir * Fix incorrect path in fish.cpp - fish is not in MacOS (it should be!)
This commit is contained in:
parent
807dc82a75
commit
63120a9962
3 changed files with 7 additions and 2 deletions
|
@ -67,6 +67,7 @@
|
|||
|
||||
/* Begin PBXBuildFile section */
|
||||
63A2C0E91CC60F3B00973404 /* pcre2_find_bracket.c in Sources */ = {isa = PBXBuildFile; fileRef = 63A2C0E81CC5F9FB00973404 /* pcre2_find_bracket.c */; };
|
||||
9C8A0F8E1D26822F001D033D /* doc in CopyFiles */ = {isa = PBXBuildFile; fileRef = 9C8A0F8C1D268206001D033D /* doc */; };
|
||||
D00769121990137800CA4627 /* autoload.cpp in Sources */ = {isa = PBXBuildFile; fileRef = D0C6FCC914CFA4B0004CE8AD /* autoload.cpp */; };
|
||||
D00769131990137800CA4627 /* builtin_test.cpp in Sources */ = {isa = PBXBuildFile; fileRef = D0F3373A1506DE3C00ECEFC0 /* builtin_test.cpp */; };
|
||||
D00769141990137800CA4627 /* color.cpp in Sources */ = {isa = PBXBuildFile; fileRef = D0B6B0FE14E88BA400AD6C10 /* color.cpp */; };
|
||||
|
@ -400,6 +401,7 @@
|
|||
dstPath = base/share/fish;
|
||||
dstSubfolderSpec = 1;
|
||||
files = (
|
||||
9C8A0F8E1D26822F001D033D /* doc in CopyFiles */,
|
||||
D033781115DC6D4C00A634BA /* completions in CopyFiles */,
|
||||
D033781215DC6D5200A634BA /* functions in CopyFiles */,
|
||||
D033781315DC6D5400A634BA /* tools in CopyFiles */,
|
||||
|
@ -468,6 +470,7 @@
|
|||
/* Begin PBXFileReference section */
|
||||
4E142D731B56B5D7008783C8 /* config.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = config.h; path = ../osx/config.h; sourceTree = "<group>"; };
|
||||
63A2C0E81CC5F9FB00973404 /* pcre2_find_bracket.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = pcre2_find_bracket.c; sourceTree = "<group>"; };
|
||||
9C8A0F8C1D268206001D033D /* doc */ = {isa = PBXFileReference; lastKnownFileType = folder; name = doc; path = user_doc/doc; sourceTree = "<group>"; };
|
||||
D00769421990137800CA4627 /* fish_tests */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = fish_tests; sourceTree = BUILT_PRODUCTS_DIR; };
|
||||
D00F63F019137E9D00FCCDEC /* fish_version.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = fish_version.cpp; sourceTree = "<group>"; };
|
||||
D01A2D23169B730A00767098 /* man1 */ = {isa = PBXFileReference; lastKnownFileType = text; name = man1; path = pages_for_manpath/man1; sourceTree = BUILT_PRODUCTS_DIR; };
|
||||
|
@ -721,6 +724,7 @@
|
|||
D0A084F013B3AC130099B651 = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
9C8A0F8C1D268206001D033D /* doc */,
|
||||
D0D02A91159845EF008E62BD /* Sources */,
|
||||
D0D02AFC159871BF008E62BD /* Launcher */,
|
||||
D0D02A8E15983D5F008E62BD /* Libraries */,
|
||||
|
@ -1221,7 +1225,7 @@
|
|||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
shellPath = /bin/sh;
|
||||
shellScript = "cd \"${SRCROOT}\" ;\n# Run build_documentation.sh\n# Do this in a subshell so that we keep going even if it calls exit\nif [ -f lexicon_filter ] ; then\n export INPUT_FILTER=./lexicon_filter\nelse\n echo \"build_documentation:0: warning: lexicon_filter not found, ignoring it\" >&2\nfi\n\n( . \"./build_tools/build_documentation.sh\" \"./Doxyfile.help\" \"./doc_src\" \"$BUILT_PRODUCTS_DIR\" )\n\n# Copy certain files into man1, destined for share/man/man1 (instead of share/fish/man/man1)\n# These copies will fail if the documentation did not build; that's OK\n# We want to create the directory even if the documentation did not build, so that the Xcode build can still succeed\nmanpathdir=\"${BUILT_PRODUCTS_DIR}/pages_for_manpath/man1\"\necho \"Copying pages destined for manpath into $manpathdir\"\nrm -Rf \"$manpathdir\"\nmkdir -p \"$manpathdir\"\nfor manpage in fish.1 set_color.1 fishd.1 fish_indent.1; do\n manpagepath=\"${BUILT_PRODUCTS_DIR}/man/man1/${manpage}\"\n test -f \"$manpagepath\" && cp \"$manpagepath\" \"${BUILT_PRODUCTS_DIR}/pages_for_manpath/man1/\"\ndone\n\n# Always succeed\ntrue\n";
|
||||
shellScript = "cd \"${SRCROOT}\" ;\n# Run build_documentation.sh\n# Do this in a subshell so that we keep going even if it calls exit\nif [ -f lexicon_filter ] ; then\n export INPUT_FILTER=./lexicon_filter\nelse\n echo \"build_documentation:0: warning: lexicon_filter not found, ignoring it\" >&2\nfi\n\n( . \"./build_tools/build_documentation.sh\" \"./Doxyfile.help\" \"./doc_src\" \"$BUILT_PRODUCTS_DIR\" )\n\n# Copy certain files into man1, destined for share/man/man1 (instead of share/fish/man/man1)\n# These copies will fail if the documentation did not build; that's OK\n# We want to create the directory even if the documentation did not build, so that the Xcode build can still succeed\nmanpathdir=\"${BUILT_PRODUCTS_DIR}/pages_for_manpath/man1\"\necho \"Copying pages destined for manpath into $manpathdir\"\nrm -Rf \"$manpathdir\"\nmkdir -p \"$manpathdir\"\nfor manpage in fish.1 fish_indent.1; do\n manpagepath=\"${BUILT_PRODUCTS_DIR}/man/man1/${manpage}\"\n test -f \"$manpagepath\" && cp \"$manpagepath\" \"${BUILT_PRODUCTS_DIR}/pages_for_manpath/man1/\"\ndone\n\n# Always succeed\ntrue\n";
|
||||
};
|
||||
/* End PBXShellScriptBuildPhase section */
|
||||
|
||||
|
|
|
@ -4,5 +4,6 @@ function fish_config --description "Launch fish's web based configuration"
|
|||
if count $argv >/dev/null
|
||||
set initial_tab $argv[1]
|
||||
end
|
||||
set -x __fish_bin_dir $__fish_bin_dir
|
||||
eval (string escape $__fish_datadir/tools/web_config/webconfig.py) $initial_tab
|
||||
end
|
||||
|
|
|
@ -126,7 +126,7 @@ static struct config_paths_t determine_config_directory_paths(const char *argv0)
|
|||
// link CF, use this lame approach to test it: see if the resolved path ends with
|
||||
// /Contents/MacOS/fish, case insensitive since HFS+ usually is.
|
||||
if (!done) {
|
||||
const char *suffix = "/Contents/MacOS/fish";
|
||||
const char *suffix = "/Contents/Resoruces/base/bin/fish";
|
||||
const size_t suffixlen = strlen(suffix);
|
||||
if (has_suffix(exec_path, suffix, true)) {
|
||||
// Looks like we're a bundle. Cut the string at the / prefixing /Contents... and
|
||||
|
|
Loading…
Reference in a new issue