小编Ert*_*oğa的帖子

Docker官方注册表(Docker Hub)URL

泊坞中心官方网站已移到https://registry.hub.docker.comhttps://hub.docker.com/.

如果我尝试docker pull从URL中的图像:docker pull registry.hub.docker.com/busybox它显示:

registry.hub.docker.com/busybox: this image was pulled from a legacy registry.  
Important: This registry version will not be supported in future versions of docker.
Run Code Online (Sandbox Code Playgroud)

但是,如果我使用docker pull registry.hub.docker.com/busybox.

它无法拉动图像.

使用时的情况相同 curl -k https://registry.hub.docker.com/v1/repositories/busybox/tags

docker dockerhub

35
推荐指数
6
解决办法
7万
查看次数

如何使用URL和反斜杠禁用zsh替换/自动完成

我使用zshoh-my-zsh在Ubuntu:14.04.

当我粘贴URL时,shell使用反斜杠自动填充转义字符.

例如,使用环境变量:

$ wget http://{DEFAULT_IP}/index.html
It will become:
$ wget http://\{DEFAULT_IP\}/index.html
Run Code Online (Sandbox Code Playgroud)

如何禁用此功能?

zsh zshrc oh-my-zsh

8
推荐指数
3
解决办法
6248
查看次数

在python中按特定顺序排序元素

如何按自定义顺序对其进行排序?

输入:

[
    {value: "typeA"},
    {value: "typeC"},
    {value: "typeB"},
    {value: "typeC"},
    {value: "typeB"},
    {value: "typeA"}
]
Run Code Online (Sandbox Code Playgroud)

期待结果:

[
    {value: "typeB"},
    {value: "typeB"},
    {value: "typeC"},
    {value: "typeC"},
    {value: "typeA"},
    {value: "typeA"}
]

my_own_order = ['typeB', 'typeC', 'typeA']
Run Code Online (Sandbox Code Playgroud)

我的python代码现在如下:

result = sorted(input, key=lambda v:v['value'])
Run Code Online (Sandbox Code Playgroud)

python sorting dictionary list

8
推荐指数
2
解决办法
9120
查看次数

标签 统计

dictionary ×1

docker ×1

dockerhub ×1

list ×1

oh-my-zsh ×1

python ×1

sorting ×1

zsh ×1

zshrc ×1