寻找更好的Windows XP命令行界面.Visual Studio命令提示符不如Linux/OSX终端好.
思考?
编辑:
答案:Sourceforge上的控制台和Windows Powershell.谢谢,我会去挖掘它们并对它们进行评估.Cygwin包对我想要的开销太大了.
edit2: 现在看起来像Windows Powershell.它的复制和粘贴功能不是很好,但MS支持它.
我正在寻找嵌入式处理器的分类.哪些处理器属于哪个系列?谁下了谁?
这里有没有人知道描述它的简单文章?
我在本地机器上有几个存储库.一个是我的主要代码,另一个是各种有用的代码/工具.这是两个根本不同的回购.它可能是有意义的建立一个新的回购,并作为子回购拉这两个,但我想等到水银开发者纪念之前,我做的是子回购作为非实验.
其中一个有用的代码文件变得如此有用,我想把它放到我的主代码区......但我想保留它的历史.当然,这会产生一些fork的变体,但这是可以接受的.(最好的情况是能够来回拉动并不断更新其历史).
我希望能够(合理地)在Perl调试器中任意设置我的执行点.例如,在if的主体之前移动if并设置变量.
围绕perldebug(以及perldebguts和perl调试器POD)页面进行翻查表明,这种功能要么不受支持,要么没有记录.
我想这样做的相当于chmod -w+r-x foo
或attrib +R foo
在Windows PowerShell.Putzing的时候,我注意到一个相当粗糙的Set-Acl
功能,看起来显著比我需要的票友.
如何attrib +R foo
在Windows Powershell中执行此操作?
假设我有这个奇妙的功能foo
[92]> (defun foo () (lambda() 42))
FOO
[93]> (foo)
#<FUNCTION :LAMBDA NIL 42>
[94]>
Run Code Online (Sandbox Code Playgroud)
现在,假设我想实际使用 foo并返回42.
我怎么做?我一直在谷歌周围徘徊,我似乎无法提出正确的语法.
假设我有一些代码:
let listB = [ 1; 2; 3 ]
Run Code Online (Sandbox Code Playgroud)
使用Lisp表示法,我该如何处理car
并cadr
反对此列表?我知道缺点是::
.
或者在Scheme中,first
和rest
?
我正在编写一个例程来测试点是否在实际的最后一行.
(defun end-of-line-p ()
"T if there is only \w* between point and end of line"
(interactive)
(save-excursion
(set-mark-command nil) ;mark where we are
(move-end-of-line nil) ;move to the end of the line
(let ((str (buffer-substring (mark) (point)))) ;; does any non-ws text exist in the region? return false
(if (string-match-p "\W*" str)
t
nil))))
Run Code Online (Sandbox Code Playgroud)
问题是,在运行它时,我在迷你缓冲窗口中看到"标记集",而不是T或nil.
这拒绝编译.注释掉该(setf roll
行可以编译.但是,(setf roll...
它本身在REPL中正确评估.
程序:
;; loop n times
; sum up number of hits over value v
(defun num-hits (n v)
(let
((roll)
(table))
(setq table (make-hash-table))
;;until i == n
(loop for i from 1 to n
(setf roll (rolld6))
; (if (nilp (view_hash table))
; (oxuassign_hash table roll 1)
; (assign_hash table (+ 1 (view_hash table roll))))
)
(+ (view_hash table 5) (view_hash table 6))))
Run Code Online (Sandbox Code Playgroud)
信息:
*** - LOOP: illegal syntax near (SETF ROLL …
Run Code Online (Sandbox Code Playgroud) 我正在尝试为clisp创建一个像这样工作的"系统"命令
(setq result (system "pwd"))
;;now result is equal to /my/path/here
Run Code Online (Sandbox Code Playgroud)
我有这样的事情:
(defun system (cmd)
(ext:run-program :output :stream))
Run Code Online (Sandbox Code Playgroud)
但是,我不确定如何将流转换为字符串.我已经多次回顾了hyperspec和google.
编辑:使用Ranier的命令并使用with-output-to-stream,
(defun system (cmd)
(with-output-to-string (stream)
(ext:run-program cmd :output stream)))
Run Code Online (Sandbox Code Playgroud)
然后试着跑grep
,这是我的道路......
[11]> (system "grep")
*** - STRING: argument #<OUTPUT STRING-OUTPUT-STREAM> should be a string, a
symbol or a character
The following restarts are available:
USE-VALUE :R1 Input a value to be used instead.
ABORT :R2 Abort main loop
Break 1 [12]> :r2
Run Code Online (Sandbox Code Playgroud) lisp ×3
common-lisp ×2
clisp ×1
command-line ×1
debugging ×1
elisp ×1
emacs ×1
embedded ×1
f# ×1
lambda ×1
list ×1
mercurial ×1
perl ×1
permissions ×1
powershell ×1
shell ×1
stream ×1
taxonomy ×1
upgrade ×1
windows-xp ×1