Gitlab自动更改日志创建

问题描述

我想知道如何创建CHANGELOG.md整体文件。 我已经看过该站点https://docs.gitlab.com/charts/development/changelog-manager.html,但是我不知道在哪里可以找到changelog_manager.rb以及如何正确调用它,因此我从多个changelog条目(https://docs.gitlab.com/charts/development/changelog.html中获得了一个整体CHANGELOG.md。

谢谢。

解决方法

您可以在https://gitlab.com/gitlab-org/charts/gitlab/-/tree/master上克隆仓库。

引用的脚本名称min(date)在此存储库中不再存在,按照内容和历史记录,我会说它已经过重构/重组,今天您将使用class Sample extends React.Component<Props,State> { constructor(props: Props) { super(props); this.state = { channel: -1,sports: -1,movie: "" }; } handleChange = (e: any) => { this.setState({ channel: e.target.value }); }; handleSports = (e: any) => { this.setState({ sports: e.target.value }); }; handleMovie = (e: any) => { this.setState({ movie: e.target.value }); }; Valid = () => { const errors = { channel: "",sports: "",movie: "" }; if (!this.state.channel) { errors.channel = "Please select channel"; } if (!this.state.sports) { errors.sports = "select Sports"; } if (!this.state.movie) { errors.movie = "select movie"; } return { errors,isSubmit: Object.keys(errors).length === 0 }; }; handleSubmit = (e: any) => { e.preventDefault(); const data = { channel: this.state.channel,sports: this.state.sports,movie: this.state.movie }; console.log(data); }; render() { const { errors,isSubmit } = this.Valid(); return ( <> <FormControl> <Select defaultValue={-1} onChange={this.handleChange} displayEmpty inputProps={{ "aria-label": "Without label" }} > <MenuItem value={-1}>Select Channel</MenuItem> <MenuItem value={10}>Sports</MenuItem> <MenuItem value={20}>Entertainment</MenuItem> </Select> {!this.state.channel ? ( <FormHelperText>{errors.channel}</FormHelperText> ) : null} </FormControl> {this.state.channel === 10 ? ( <div> <FormControl> <Select defaultValue={-1} onChange={this.handleSports} displayEmpty inputProps={{ "aria-label": "Without label" }} > <MenuItem value={-1}>Select </MenuItem> <MenuItem value={10}>Star sports 1</MenuItem> <MenuItem value={20}>Star sports 2</MenuItem> </Select> {!this.state.sports ? ( <FormHelperText>{errors.sports}</FormHelperText> ) : null} </FormControl> </div> ) : this.state.channel === 20 ? ( <div> <FormControl> <Select defaultValue={-1} onChange={this.handleMovie} displayEmpty inputProps={{ "aria-label": "Without label" }} > <MenuItem value={-1}>Select</MenuItem> <MenuItem value={10}>Star Movies</MenuItem> <MenuItem value={20}>ABC</MenuItem> </Select> {!this.state.movie ? ( <FormHelperText>{errors.movie}</FormHelperText> ) : null} </FormControl> </div> ) : null} <div> <Button disabled={isSubmit} onClick={this.handleSubmit}> Submit </Button> </div> </> ); } } export default Sample;

相关问答

Selenium Web驱动程序和Java。元素在(x,y)点处不可单击。其...
Python-如何使用点“。” 访问字典成员?
Java 字符串是不可变的。到底是什么意思?
Java中的“ final”关键字如何工作?(我仍然可以修改对象。...
“loop:”在Java代码中。这是什么,为什么要编译?
java.lang.ClassNotFoundException:sun.jdbc.odbc.JdbcOdbc...