Emacs Lisp ããæ¸ãããããã«ãªãã¾ã§
å æ¥ã®é¢è¥¿Emacsã§ã¯ãEmacs Lisp ã®å ¥éè¨äºããããã¨ãããæ¸ãããããã«ãªãæ å ±ããªããããã¨ãã話ãèãã¾ããã確ãã«ãEmacsã®åæ©çãªæä½å ¥éã¨ãè¯ãæ¸ãã人ãã¢ããªãããã°ãªã©ã§elispãã°ãã£ã¨æ¸ãã¦ãã®ã¯ããè¦ã¾ããå ¥éããæ¸ããããã«ãªãã¾ã§ã®éã®éç¨ã¯è¦ããã¨ç¡ãã£ããããããªãã¨æãã¾ããã
ã¨ãããã¨ã§ãEmacsã®å 人ãã¡ã«ã¯ã¾ã ã¾ã åã³ã¾ããããããã¤ãã®ã¢ããªãæ¸ãã¦ã¿ãèªåããã©ã£ãæ¹æ³ãæ¸ãã¦ã¿ã¾ããå ã«ã¾ã¨ããã¨ä»¥ä¸ã®2ã¤ã«ãªãã¨æãã¾ãã
- elispã§ã©ããã¦ãæ¸ãããç©ããããã¨
- ããããæ¸ãã¦åããã¦ï¼ãã£ã¡ãå ï¼ãããã¦Infoãä»äººã®ã³ã¼ããè¦ã¦åå¼·ãã
æ¸ãã以åã®ã¾ã¨ã
- Emacsæ´10年以ä¸ããã§ã«çæ´»ã®ä¸é¨ã
- ã§ãè¨å®ãæ¸ãã®ã«ä½¿ã£ã¦ãããããã
- æ¢åã®ã¢ããªã®åããããããã°ãæå ã§ã¡ãã£ã¨ç´ãã¨ãã
- LISPç³»ã®è¨èªã¯ãSICPã¨ãã§Schemeã¯ããã¨æ¸ãã¦ãããããã
- Javaã¨ãä»ã®è¨èªã§ã¯ã¢ããªã¯ããããæ¸ãã¦ããã
æ¸ããã¨æã£ãåæ©
å°ããé¢æ°ã¯æ¸ãã¦ãã¾ããããããã ãã§ã¯ãã¾ãæ¸ãã¦ããæ°åã¯ãã¦ã¾ããã§ãããã¨ã«ãããã¡ã¸ã£ã¼ã¢ã¼ãããã¤ãã¼ã¢ã¼ããæ¸ããªãã¨ãelispæ¸ããï¼ãã¨è¨ããªãæ°ããã¦ãã¾ããã
ä¸åº¦ãã®é ãLinuxä¸ã®Skypeã使ãå§ããã®ã§ããããã¾ãã®ä½¿ãã«ããã«é©ãã¦ããã¯ä½ã¨ãããªããã°ã¨æã£ã¦ãã¾ãããæ¢åã®ã³ã¼ãã§Emacsã§Skypeãæä½åºæ¥ãªãããããã調ã¹ãã®ã§ããã欲ããç©ãå ¨ç¶è¦ã¤ããã¾ããã§ããã
ãã°ããSkypeã®APIã調ã¹ã¦Emacsã®dbusã§å®é¨ãã¦ãããã¡ã«ä½ã¨ãªãèªåã§ä½ããããªæå¿ããæããã®ã§ããEmacsä¸ã§Skypeã¯ã©ã¤ã¢ã³ããä½ããã¨ãããã¨ãå¼·ãç®æ¨ã«ãªãã¾ããã
å¤åããç¡ããã®ã¯ä½ã£ã¦ãã¾ããã¨ããå®é¨ãã¦ãããã¡ã«ä½ããããªæå¿ããæãããã¨ããã¨ããã¯ããããããã®ã§ã¯ãªãããããã¾ããããä»ã®è¨èªã§ããããã®éçºçµé¨ããã£ãã®ã§ããæããã®ã ã¨æãã¾ãã
åãããªããªãã«èª¿ã¹ã¦æ¸ãã¦ã¿ã
ã¾ããemacs-dbusã®æ å ±ã¯å½æï¼2008å¹´é ï¼ã»ã¨ãã©ç¡ãã£ãã®ã§ãEmacsã®Infoï¼è±èªï¼ã¨æå ã§ã®å®é¨ã§æ å ±ãã¾ã¨ãã¦ããã¾ããã
次ã«ãã£ããã表示ããã¡ã¸ã£ã¼ã¢ã¼ããå¿ è¦ãªãã ãããªã¨ã¼ãããæã£ã¦ãã¦ã以ä¸ã®ãã¼ã¸ãèªã¿ã¾ããã
ãåªããããã®æ¹ã¯ãelispãæ¸ãå§ããã¨æ®éã«æ¬²ããæ å ±ãããã£ã¦ãã¾ãã®ã§ããªãåèã«ãªãã¨æãã¾ããããæåèªãã ã¨ãã¯åãããªããã¨ãå¤ããã¦ãã¾ãç解ã§ãã¦ãã¾ããã§ããã
ããããããã®æ¹ã¯å ·ä½çã§å 容ãçããåããããã¨ãã¦ä¸åº¦è¯ãã£ãã§ããã¾ããã³ã¼ãã¯åçµãã¾ããã
ããã§ããã¹ãå¦çã«ã¤ãã¦ã¯ããç¨åº¦æ¸ããããã«ãªãã¾ããã
ãã®æç¹ã§ã¯ãã³ã¼ãã¯ãããæ £ãã¦ãªãæãã®ã³ã¼ãã§ããSchemeã®å½±é¿ãå¼·ãåãã¦ãã¦ãç¹ã«ã«ã¼ãã¯mapç³»é¢æ°ã使ã£ã¦ãã¾ããããã©ããã¦ãåé·ãªã³ã¼ãã«ãªã£ã¦ãã¾ãããã«ã¼ããããã®ã«æ·±ãå帰ãã§ããªãã¨ããã®ãããªãã®è¶³ããã§ããã¾ãããfuncallããæ¸ããªãã¨é¢æ°ãå¼ã¹ãªããã¨ããé¢æ°å é¢æ°ãæ¸ããªããã¨ããããã©ã«ãã§ã¬ãã·ã«ã«ã¹ã³ã¼ãã§ãªãã£ãããSchemeã«æ¯ã¹ã¦ããªãæ¸ãã¥ããå°è±¡ãããã¾ããã
ã¾ãããã©ã³ããè²ãç»åãªã©ã表示ãããã£ãããã¦ã¤ã³ãã¦ã®å¶å¾¡ããããã£ãã®ã§ãããã©ããã£ãæ¤ç´¢ãã¼ã§æ¢ãã°ããã®ããã©ããªæ å ±ã»ãããå¿ è¦ãªã®ããããã«ã¯ã©ãæ¸ãã°ããã®ãå ¨ç¶åããã¾ããã§ããã
ãªãã¡ã¬ã³ã¹ãèªã
ã¨ãããã¨ã§ãä½ç³»çãªæ å ±ãå¾ãããã« Emacs Lisp ã®ãªãã¡ã¬ã³ã¹ãèªããã¨ã«ãã¾ãããæ¥æ¬èªçã¯ä»¥ä¸ã®21.3çãããã¾ãã®ã§ããããæºå¸¯ã®ãã©ã¦ã¶ããæ¯æ¥èªãã§ã¾ããã
ææ°ã®æ å ±ã¯ãEmacs23ã«ä»å±ã®è±èªçInfoã§è£ãã¾ãããç®æ¬¡ããã£ã¨çºããªããã追å ããã¦ããé ç®ãèªãã§ããæãã§ãã
ã¾ããä»ã®äººã®elispã³ã¼ããããããèªãã§ã¿ãã¨ãclããã±ã¼ã¸ãããªã使ã£ã¦ãããã¨ãåããã¾ããã®ã§ãclããã±ã¼ã¸ã®ãªãã¡ã¬ã³ã¹ãèªã¿ã¾ããã以ä¸ãåèã«ãªãURLã§ãã
ããã§ãåç¥èãé ã®ä¸ã§æ´çããã¦ãelispã®æ å ±ã®ã¤ã³ããã¯ã¹ãæ§ç¯ããã¾ããã
ã¬ãã·ã«ã«ã¹ã³ã¼ããã«ã¼ãã®æ¸ãæ¹ã®éåæã«ã¤ãã¦ã¯ãlexical-letãloopãã¯ãã§è§£æ¶ãã¾ãããç¹ã«loopãã¯ãã¯ç¸å½ä¾¿å©ã§ãããããªãå ¨é¨ã®å¥ãè¦ãããã¨ããã«ãã¾ãã¯dolistãmapcã®ä»£ããããå°ããã¤ä½¿ãå§ããã°è¯ãã¨æãã¾ãã
ã¾ããfuncallãåå空éã®åé¡ã«ã¤ãã¦ããæ°æã¡ã®åé¡ã ã¨åãæ¿ãããã¨ã§è§£æ±ºãã¾ãããJavaã®äººããJavaScriptã®ã¯ã©ã¹ã§ã¯ããããã£ãåºæ¬å ¨é¨publicãã¨ããRubyã¯å®£è¨ç¡ãã§å¤æ°ã使ãããã¨ãããã¨ã«æ £ãããããªãã®ã ã¨æãã¾ããè¨èªã«ã¯ããããæåãããã®ã§ã以åã®è¨èªã®æåã«åºå·ããã®ã¯è¯ããªãã§ãããï¼ä¸æ¹ã§ãä»ã®è¨èªã«ããã¢ã¤ãã¢ãæã£ã¦ãããã¨ã§ãã¬ã¼ã¯ã¹ã«ã¼ãéãããã¨ãããã®ã§ããã£ã±ãæ¸ãã¦èªãã§ãã³ã¼ãã«ã¤ãã¦èãããã¨ãå¿ è¦ãªã®ããªã¨æãã¾ããï¼
ããã¾ã§æ¥ã¦ãããªãã®ã³ã¼ããæ¸ããããã«ãªãã¾ããããã ãã¾ã ã¾ã æªç¥ã®é åãããã¾ããã
ãã¯ã
ä»äººã®ã½ã¼ã¹ãè¦ã¦ãã¦ãå¯ä¸èªããªãã¨ããããã¯ãã§ãããä½ã¨ãªãé»éè¡ã®ãããªæ°ããã¦ãã¦ãè¿ã¥ããªãæ¹ãè¯ãã®ãããããªãã¨æã£ã¦ãã¾ããã
ãã®ã¨ããä¸åº¦ OnLisp ãèªãã§ãã¾ãããå®ã¯ãããä½ã«ã¤ãã¦æ¸ãã¦ããæ¬ã ãç¥ããã«èªã¿å§ããã®ã§ãããç¸å½è¡æãåãããã¨ãè¦ãã¦ãã¾ããèªåã®äººçã®ä¸ã§SICPã®æ¬¡ã«è¡æãåããããããã¾ããããã®ä»¶ã«ã¤ãã¦ã¯ã¾ãå¾ã»ã©æ¸ããããã¨ãããã®ã§ãããã¨ããããä¸æ°ã«èªåã«ãã¯ãåãã¤ãã¾ããã
èªããã³ã¼ãã®ç¯å²ãåºããªããï¼ãã¯ãã使ããªãã«ãã¦ãï¼æ¸ãã³ã¼ãã®è³ªãä¸ãã£ããããªæ°ããã¾ãã
ã¨ãããã¨ã§ãèªããã³ã¼ããå¶éããããã¨ã¯è¯ããªãã®ã§ãelispããæ¸ãããããã«ãªãã«ã¯ãã¯ãã¯èº«ã«ã¤ãã¦ããæ¹ãè¯ãã®ã§ã¯ãªãããªã¨æãã¾ãã
èªåã®ã«ã¼ã«ã§ã¯ã極åé¢æ°ã§ããã¨ããã¯é¢æ°ã§æ¸ãã¦ãæ½è±¡åã®éå ·ã¨ãã¦ã¯ãã¾ããã¯ãã¯ä½¿ããªãããã«ãã¦ãã¾ããããã¯ãã§æ¸ããæ¹ãè¦éããè¯ããªãï¼æ¸ãæã®æå³ãä¼ãããããï¼ãããªã¨ããï¼ä¾ãã° aif, acond ãªã©ï¼ã«ã¯ãã使ã£ã¦ãã¾ããã¾ãããã¯ãã§ããåºæ¥ãªãã³ã¼ããããã¾ãã®ã§ãããããã¨ãã«ã¯ç©æ¥µçã«ä½¿ã£ã¦ãã¾ãã
ããããæ¸ãã¦ãããããèªã
ããã¾ã§ã§ä¸éããããããã¨ãå®ç¾ã§ããããã«ãªããskype.elãä½ã¨ãå®æãã¾ããããã¡ããããµã¤ã¨ãããããããããã¾ããæ¸ããé åãåºããã¨æ¥½ãããã®ã§ãããããããä½ããããä½ãããã¨æãããã«ãªãã¾ããã
ãã®æç¹ã§ã¯ã大æµã®ãããããã¨ã¯åºæ¥ãã®ã§ãããããå°ãé«ãã¬ãã«ã®æ¸ãæ¹ã§è©°ã¾ã£ã¦ãã¾ãããã«ãã»ã«åã»é è½ãã©ããããããã®ãã¨ããå ¬éç¨ã®é¢æ°ã¨å é¨ç¨ã®é¢æ°ãã©ãåããããããã¨ãããã¼ã¿ã¯ã©ãä¿æãã¦å ¨ä½ã®è¨è¨ã¯ã©ããããµãã«ãããããã®ãã¨ãããã¨ã¯ã³ã¡ã³ãã¨ãããã¥ã¡ã³ããã©ãæ¸ãã¹ãããªã©ãããããã¨è©¦è¡é¯èª¤ã®é£ç¶ã§ããã
ããããåé¡æèãããæã«ä»ã®äººã®ã³ã¼ããèªãã¨åèã«ãªãã¾ããemacsã®lispãã£ã¬ã¯ããªã¨ããEmacsWikiã¨ãå®ã®å±±ã§ããä¸ã®å ´åã¯ãçµå±ããã¾ãçµ±ä¸ãããæ¹æ³ãç¡ããã¿ããªèªåãªãã«è©¦è¡é¯èª¤ãã¦ããã¨ãããã¨ãåãã£ããããããã§ãããããã¯ããã§ãããããã®ãªã®ãã¨å®å¿ãããã人ã®ã³ã¼ããåèã«ãã¤ã¤èªåãªãã®æ¹æ³ã模索ãã¦ããã¾ããã
ä»ã¯CLã®æ¬ãªã©ã§CLãããè¨è¨ã«ã¤ãã¦åå¼·ãããã¨ãã¦ãã¾ãã
èªåã®ä»å¾
ã¨ããããæ¸ãããã³ã¼ããããããããã¾ããã¾ããèªãã§ããããã³ã¼ããããããããã¾ãã
ãã¨ã¯ãelispã®é度èªä½ã«ã¯ãã¾ãä¸æºã¯ãªãã®ã§ãããä»å¾ã¯é«éåã®æ段ã®ã²ã¨ã¤ã¨ãã¦cclãç¥ããããªã¨æã£ã¦ãã¾ãã
- http://computing.fnal.gov/docs/products/xemacs/v21_1/lispref.info,.CCL.html
- ccl.el以å¤ã«ããã¥ã¡ã³ãã¯ã©ãã»ã»ã»
ã¾ã¨ã
ã¨ãããã¨ã§ãèªåã®elispã®åå¼·ã®æ´å²ãæ¸ãã¦ã¿ã¾ããã
elispãæ¸ãããçããã®ãå½¹ã«ç«ã¦ãã¨å¹¸ãã§ãã
ãã¾ãã¨ãã¦ãStackOverFlowã®è¨äºããããããã£ãã®ã§ã¡ãã£ã¨ç´¹ä»ãããã¨æãã¾ãã
- The single most useful Emacs feature - Stack Overflow
- Emacsã®æ©è½ã®ä¸ã§å¥½ããªã¨ããã¯ä½ã§ããï¼ã¨ããåãã«å¯¾ãã¦ããããããªäººãã³ã¡ã³ããã¦ããã
- æ票1çªããM-/ãã®è£å®ã2çªç®ã align-regexã以ä¸ããããç¶ãã¦ãã
- Emacsã®è¯ãã¨ãããã²ã¨ã¤ã ããããã¨ããã®ã¯é£ããã§ããã