9
¿Es posible utilizar la herramienta "diff" sin tener archivos físicos? Algo como esto:Dif sin archivos
diff "hello" "hell"
¿Es posible utilizar la herramienta "diff" sin tener archivos físicos? Algo como esto:Dif sin archivos
diff "hello" "hell"
Puede diff entrada estándar con un archivo utilizando el nombre de archivo especial -
:
# diff the contents of the file 'some-file' with the string "foobar"
echo foobar | diff - some-file
Con fiesta, también se puede utilizar canalizaciones con nombre anónimos (un nombre poco apropiado) a diferencia de dos tuberías:
# diff the string "foo" with the string "baz"
diff <(echo foo) <(echo baz)
Ver también How can you diff two pipelines with bash?.
++ Dale un golpe. – guns