<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: What is a good practice to handle &amp;quot;%Include(s)&amp;quot;  in context of the SAS EG Git-integrat in SAS Enterprise Guide</title>
    <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/What-is-a-good-practice-to-handle-quot-Include-s-quot-in-context/m-p/859522#M42315</link>
    <description>&lt;P&gt;When you check in a .sas file containing a macro, the check-in script should be modified in such a way that it stores a copy of the file in your autocall library.&lt;/P&gt;</description>
    <pubDate>Sat, 18 Feb 2023 12:29:38 GMT</pubDate>
    <dc:creator>Kurt_Bremser</dc:creator>
    <dc:date>2023-02-18T12:29:38Z</dc:date>
    <item>
      <title>What is a good practice to handle "%Include(s)"  in context of the SAS EG Git-integration?</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/What-is-a-good-practice-to-handle-quot-Include-s-quot-in-context/m-p/859511#M42314</link>
      <description>&lt;P&gt;Hello world!&lt;/P&gt;
&lt;P&gt;we want to use the Git-integration in SAS Enterprise Guide. So we saved all SAS Programs as .sas files under git version control and linked them to SAS Enterprise Guide projetcs.&amp;nbsp;Some of the files are macros that we want to include in other programs. I've found a post with the same problem from 2016:&amp;nbsp;&lt;A href="https://communities.sas.com/t5/SAS-Programming/INCLUDE-problem-in-SAS-Enterprise-Guide/m-p/321249" target="_blank"&gt;https://communities.sas.com/t5/SAS-Programming/INCLUDE-problem-in-SAS-Enterprise-Guide/m-p/321249&amp;nbsp;&amp;nbsp;&lt;/A&gt;Is there a better solution in the meantime? The only solution I can think of is a process flow with the name autoexec in which I link all macros. Are there any other&amp;nbsp;&lt;SPAN&gt;suggestions?&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Beste regards,&lt;/P&gt;
&lt;P&gt;Klaus&lt;/P&gt;</description>
      <pubDate>Sat, 18 Feb 2023 07:10:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/What-is-a-good-practice-to-handle-quot-Include-s-quot-in-context/m-p/859511#M42314</guid>
      <dc:creator>klroesner</dc:creator>
      <dc:date>2023-02-18T07:10:22Z</dc:date>
    </item>
    <item>
      <title>Re: What is a good practice to handle "%Include(s)"  in context of the SAS EG Git-integrat</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/What-is-a-good-practice-to-handle-quot-Include-s-quot-in-context/m-p/859522#M42315</link>
      <description>&lt;P&gt;When you check in a .sas file containing a macro, the check-in script should be modified in such a way that it stores a copy of the file in your autocall library.&lt;/P&gt;</description>
      <pubDate>Sat, 18 Feb 2023 12:29:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/What-is-a-good-practice-to-handle-quot-Include-s-quot-in-context/m-p/859522#M42315</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2023-02-18T12:29:38Z</dc:date>
    </item>
    <item>
      <title>Re: What is a good practice to handle "%Include(s)"  in context of the SAS EG Git-integrat</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/What-is-a-good-practice-to-handle-quot-Include-s-quot-in-context/m-p/859556#M42316</link>
      <description>&lt;P&gt;If you want to include files from a Git repo in a new SAS session, you can use the Git functions in SAS. Example:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="sas"&gt;options dlcreatedir;
%let repopath=%sysfunc(getoption(WORK))/wordle-sas;
libname repo "&amp;amp;repopath.";
data _null_;
    rc = gitfn_clone( 
      "https://github.com/sascommunities/wordle-sas", 
      "&amp;amp;repoPath." 
    			); 
    put 'Git repo cloned ' rc=; 
run;
%include "&amp;amp;repopath./wordle-sas.sas";&lt;/LI-CODE&gt;
&lt;P&gt;If your program contains SAS macros that you would like available as AUTOCALL macros, then append the path where you cloned the repo to the SASAUTOS search:&lt;/P&gt;
&lt;LI-CODE lang="sas"&gt;options append=(sasautos="&amp;amp;repopath.");&lt;/LI-CODE&gt;
&lt;P&gt;You can then use the SAS macros just as you would the built-in macros that come with SAS.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Working in this way has the appealing outcome (to me) of being able to start from a fresh environment, and pulling the most recent SAS program content from your Git repository of record.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;See also:&amp;nbsp;&lt;A href="https://blogs.sas.com/content/iml/2023/02/06/git-share-sas-programs.html" target="_self"&gt;How to use Git to share your SAS programs&lt;/A&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 18 Feb 2023 19:06:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/What-is-a-good-practice-to-handle-quot-Include-s-quot-in-context/m-p/859556#M42316</guid>
      <dc:creator>ChrisHemedinger</dc:creator>
      <dc:date>2023-02-18T19:06:07Z</dc:date>
    </item>
    <item>
      <title>Re: What is a good practice to handle "%Include(s)"  in context of the SAS EG Git-integrat</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/What-is-a-good-practice-to-handle-quot-Include-s-quot-in-context/m-p/859602#M42317</link>
      <description>&lt;P&gt;Hi Chris, thanks for the quick reply. But I think I didn't express my point very well...:-)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The local git repository is stored on a Windows drive at development time. The workspace server is a Linux box. We don't have any shares between Windows and Linux.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So I have to transfer the macros to the server before I runinng the main program.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;These are my current solutions:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Version 1: Linked Objects&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="version1.png" style="width: 575px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/80580i7206375ECB4FB22A/image-size/large?v=v2&amp;amp;px=999" role="button" title="version1.png" alt="version1.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Version 2: autoexec Processflow&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="version2.png" style="width: 594px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/80581i6E99F8367409CB39/image-size/large?v=v2&amp;amp;px=999" role="button" title="version2.png" alt="version2.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;Or is there another solution?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best regards,&lt;/P&gt;
&lt;P&gt;Klaus&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 19 Feb 2023 09:01:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/What-is-a-good-practice-to-handle-quot-Include-s-quot-in-context/m-p/859602#M42317</guid>
      <dc:creator>klroesner</dc:creator>
      <dc:date>2023-02-19T09:01:06Z</dc:date>
    </item>
    <item>
      <title>Re: What is a good practice to handle "%Include(s)"  in context of the SAS EG Git-integrat</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/What-is-a-good-practice-to-handle-quot-Include-s-quot-in-context/m-p/859665#M42318</link>
      <description>&lt;P&gt;Having your local git repository on a drive not accessible from your SAS server is problematic. We use git in a similar way to you except each user has a local git repository on a personal SAS server folder that is also accessible from their PCs. This is the ideal setup as users can then use EG git functions to maintain their local code repositories as well as being able to use AUTOCALL macros, %INCLUDE programs etc, from within EG. If you want to, programs can also be run in batch mode.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Talk to your SAS administrator about setting up git folder locations that are accessible from both PCs and your SAS server.&amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 20 Feb 2023 01:23:11 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/What-is-a-good-practice-to-handle-quot-Include-s-quot-in-context/m-p/859665#M42318</guid>
      <dc:creator>SASKiwi</dc:creator>
      <dc:date>2023-02-20T01:23:11Z</dc:date>
    </item>
  </channel>
</rss>

