流浪汉SMB默认用户名和密码?(Vagrant SMB default username and password?)
在我重新安装Windows 10之前,我使用了使用SMB同步类型的Vagrant盒子(ubuntu / xenial64)。 现在,我以同样的方式(安装Virtual Box + Vagrant,两个最新版本),我更改了配置以使用SMB并设置mount_options。 这是配置 。 我从cmd运行管理员(Powershell和简单的cmd,试过两个)
vagrant up
,但流浪汉仍然问我用户名和密码 。 那么, 我该如何设置默认用户名和密码? 在它为我工作之前。 用户名和密码是正确的,因为当我在控制台中输入它时,其接受的成功和文件夹安装良好。Windows 10 Pro x64 1703
流浪汉1.9.5
VirtualBox 5.1.22
Box:ubuntu / xenial64谢谢
Before i reinstalled Windows 10, i had Vagrant box (ubuntu/xenial64) that used SMB sync type. Now, i do the same way (install Virtual Box + Vagrant, both latest versions), i changed the config to use SMB and set mount_options. Here is config. I run from cmd as admin (Powershell and simple cmd, tried both)
vagrant up
, but vagrant still asking me the username and password. So, how can i set default username and password? Before it works for me. The username and password is correct, because when i enter this in console, its accepted successful and folder mounts good.Windows 10 Pro x64 1703
Vagrant 1.9.5
VirtualBox 5.1.22
Box: ubuntu/xenial64Thanks
原文:https://stackoverflow.com/questions/44394725
最满意答案
您可以将此正则表达式用于
0..100
范围(包括两者):^([0-9]{1,2}|100)$
或者你的例子:
^([0-9]{1,2}|100)([,.][0-9]{1,2})?$
You can use this regex for
0..100
range (both inclusive):^([0-9]{1,2}|100)$
OR for your example:
^([0-9]{1,2}|100)([,.][0-9]{1,2})?$
相关问答
更多-
正则表达式对于货币值(Regex For value Currency)[2023-06-19]
如果你想允许价值如英镑5.32: ^[$€£]?(\d+([\.,]\d{2})?)$ 如果不: ^[$€£]?(\d+([\.,]00)?)$ 一旦你检查了它是否使用正则表达式正确格式化,你可以继续使用正则表达式的第一个返回组来检查5 < int(value) < 2000 。 编辑:考虑过它,这里是一个正则表达式,它也会照顾到边界: ^[$€£]?((([1-5],?)?\d{2,3}|[5-9])(\.\d{2})?)$ If you want to allow values like £5.32: ... -
正则表达式替换包含部分匹配的值在替补中?(Regex to replace values that include part of match in replacement in sublime?)[2021-09-04]
替换表达式是: \$\1\u\2 \1 , \2是捕获(或$1 , $2 ) \u up-cases(请参见“ 替换字符串语法”部分 )。 有关更多信息,请参阅正则表达式一章 (在TextMate文档中 ) 。 已经有一个包可以做到这一点,还有更多: 关于CaseConversion的简要博客 CaseConversion包 The replacement expression is: \$\1\u\2 \1, \2 are the captures (or $1, $2) \u up-cases (s ... -
使用以下正则表达式(使用捕获组)并从组索引1获取JSESSIONID的值。 JSESSIONID[^;=]*=([^;]+) Use the below regex(which uses capturing group) and get the value of JSESSIONID from group index 1. JSESSIONID[^;=]*=([^;]+)
-
C#正则表达0-100 [重复](C# Regex for 0-100 [duplicate])[2023-09-15]
您可以使用以下模式匹配0到100之间的数字, ^(?:100|[1-9]?[0-9])$ DEMO 说明: ^断言我们刚开始。 (?:)仅进行匹配操作的非捕获组。 100匹配字符串100。 | 逻辑OR运算符用于OR两个正则表达式。 [1-9]? 匹配范围1到9中的任何一个数字之一? 在字符类使它成为可选之后。 [0-9]匹配0到9范围内的任何一个数字。 $断言我们在行尾。 You could use the below pattern to match the digits from 0 to 100, ... -
Python正则表达式(从字符串中提取货币值)(Python regular expressions (extracting monetary value from a string))[2022-10-10]
尝试: re.findall('£{1}[,0-9]{1,10}','The little £250,000 brown fox jumped over the lazy dog') 然后取出匹配的结果并删除逗号。 Try: re.findall('£{1}[,0-9]{1,10}','The little £250,000 brown fox jumped over the lazy dog') Then take the result of the match and strip commas ou ... -
您可以将此正则表达式用于0..100范围(包括两者): ^([0-9]{1,2}|100)$ 或者你的例子: ^([0-9]{1,2}|100)([,.][0-9]{1,2})?$ You can use this regex for 0..100 range (both inclusive): ^([0-9]{1,2}|100)$ OR for your example: ^([0-9]{1,2}|100)([,.][0-9]{1,2})?$
-
匹配范围的正则表达式(Regex expression for matching ranges)[2023-11-17]
如何提取组: \b(?[1-9][0-9]{1,4})(-(? [1-9][0-9]{1,4}))?; 永久链接到RegexStorm,包括两个无效的测试用例1234-和12345678912345 。 然后检查它是否包含任何字母只需使用下面的表达式: [A-Za-z] 并通过以下方式验证: Regex regex = new Regex("[A-Za-z]"); if (regex.IsMatch(inputString)) { //Invalid st ... -
您可以使用以下模式: ^(?:[1-9]?\d|100)$ 它将允许下面的100和其他数字,但不允许从0开始的数字,如01 。 空白也不匹配,但仅有0 。 请参阅正则表达式演示 You can use the following pattern: ^(?:[1-9]?\d|100)$ It will allow 100 and other number below, but not numbers starting with 0such as 01. Blank is also not matched ...
-
这似乎更容易 使用^(?!0$)明确排除0, 使用^(?!0?0\.0)明确地排除小于0.1的任何东西 明确包括100。 其余的是任意两位数字,带有可选的小数部分(最多5位数): ^(?!0$)(?!0?0\.0)(?:100|\d{1,2}(?:\.\d{1,5})?)$ 演示: https : //regex101.com/r/Di2l1l/6 It seems to be easier to explicitly exclude 0 using ^(?!0$), explicitly exclude ...
-
你可以这样做: ^(([1-9]\d?)|100)$ 这将确保这一点 至少有一个数字 多位数字以零以外的数字开头 唯一允许的三位数字是100。 You can do it like this: ^(([1-9]\d?)|100)$ This would ensure that There is at least one digit That multi-digit numbers start in a digit other than zero That the only allowed three-d ...